# 3D html (webgl) to .obj or .stl

**URL:** <https://discourse.threejs.org/t/3d-html-webgl-to-obj-or-stl/4530>\
**Category:** Questions\
**Tags:** obj-format\
**Created:** [October 16, 2018, 4:18pm UTC](https://discourse.threejs.org/t/3d-html-webgl-to-obj-or-stl/4530 "2018-10-16T16:18:27Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![AKoperski](https://avatars.discourse-cdn.com/v4/letter/a/ba9def/32.png) [@AKoperski](https://discourse.threejs.org/u/AKoperski)\
**Post date:** [October 16, 2018, 4:18pm UTC](https://discourse.threejs.org/t/3d-html-webgl-to-obj-or-stl/4530/1 "2018-10-16T16:18:27Z")

</div>

Is there a program or way to open webgl model (.html) and save it as .obj?  
I want to 3D print and I need .obj file format.  
Thank you

Andy

---

<div class="post-metadata">

**Author:** ![donmccurdy](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/donmccurdy/32/33209_2.png) [@donmccurdy](https://discourse.threejs.org/u/donmccurdy)\
**Post date:** [October 16, 2018, 4:24pm UTC](https://discourse.threejs.org/t/3d-html-webgl-to-obj-or-stl/4530/2 "2018-10-16T16:24:55Z")

</div>

You’ll need to provide more detail about what you’re trying to do — an HTML file could contain anything at all, and isn’t necessarily a 3D model or even related to WebGL. If you have a scene in three.js, you can probably use `THREE.OBJExporter` to create an OBJ. If you can’t create the scene in three.js, I don’t think three.js will help you export to OBJ here.

---

<div class="post-metadata">

**Author:** ![AKoperski](https://avatars.discourse-cdn.com/v4/letter/a/ba9def/32.png) [@AKoperski](https://discourse.threejs.org/u/AKoperski)\
**Post date:** [October 16, 2018, 5:00pm UTC](https://discourse.threejs.org/t/3d-html-webgl-to-obj-or-stl/4530/3 "2018-10-16T17:00:59Z")

</div>

Hi Don,  
I know Three.js can export .obj but I am unable to load the .html file into the Three.  
See the file. [S1 3D.rar](https://canada1.discourse-cdn.com/flex035/uploads/threejs/original/2X/3/30d1082929ca4442dcba1556255e851364f4a61f.rar) (2.5 MB)

---

<div class="post-metadata">

**Author:** ![donmccurdy](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/donmccurdy/32/33209_2.png) [@donmccurdy](https://discourse.threejs.org/u/donmccurdy)\
**Post date:** [October 17, 2018, 3:47am UTC](https://discourse.threejs.org/t/3d-html-webgl-to-obj-or-stl/4530/4 "2018-10-17T03:47:15Z")

</div>

The HTML is just a wrapper around pretty much anything… you won’t be able to convert the HTML file directly. If you look at line 1809 you’ll see a long string of data, which is the content of a ZLB file. That contains the actual 3D data. Unfortunately threejs is not going to be much help to you here… even if you extract the ZLB file from the HTML, I don’t know what to do with it.

---

<div class="post-metadata">

**Author:** ![Fyrestar](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/fyrestar/32/52793_2.png) [@Fyrestar](https://discourse.threejs.org/u/Fyrestar)\
**Post date:** [October 17, 2018, 9:25am UTC](https://discourse.threejs.org/t/3d-html-webgl-to-obj-or-stl/4530/5 "2018-10-17T09:25:09Z")

</div>

This is a minified viewer loading a embeded file. From the site u’ve downloaded the standalone viewer like this file:

> **[Backpack accessories](https://b2b.partcommunity.com/community/partcloud/index?route=part&name=Backpack+accessories&model_id=75765)**
>
> A simple part for my backpack.

When you download a file there you can select a format, just select OBJ, not WebGL HTML, it’s a standalone viewer.

---

<div class="post-metadata">

**Author:** ![donmccurdy](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/donmccurdy/32/33209_2.png) [@donmccurdy](https://discourse.threejs.org/u/donmccurdy)\
**Post date:** [October 17, 2018, 3:03pm UTC](https://discourse.threejs.org/t/3d-html-webgl-to-obj-or-stl/4530/6 "2018-10-17T15:03:26Z")

</div>

That sounds much more manageable 😅

---

<div class="post-metadata">

**Author:** ![AKoperski](https://avatars.discourse-cdn.com/v4/letter/a/ba9def/32.png) [@AKoperski](https://discourse.threejs.org/u/AKoperski)\
**Post date:** [October 17, 2018, 3:21pm UTC](https://discourse.threejs.org/t/3d-html-webgl-to-obj-or-stl/4530/7 "2018-10-17T15:21:03Z")

</div>

Unfortunately I am unable to save this file as .obj or any other format.  
I have only this .html file.  
But somehow the browser interprets the geometry and so there should be a way to get it back to obj or other format.

Thank you  
Andy
