# \#examples

**URL:** https://discourse.threejs.org/tag/examples/29.md

[Latest](https://discourse.threejs.org/latest.md) · [Categories](https://discourse.threejs.org/categories.md) · [Tags](https://discourse.threejs.org/tags.md)

---

## [Create a "floating" header like in the examples?](https://discourse.threejs.org/t/create-a-floating-header-like-in-the-examples/93936)

<div class="topic-metadata">

**Author:** [@SimRuJ](https://discourse.threejs.org/u/SimRuJ)\
**Replies:** 3\
**Last updated:** [September 1, 2026, 12:29pm UTC](https://discourse.threejs.org/t/create-a-floating-header-like-in-the-examples/93936 "2026-09-01T12:29:01Z")

</div>

Hi, a lot of examples (e.g. this one with a pot) use a transparent header that is displayed on top of the scene, so whatever object is displayed in it, still shows up behind the header. I looked at the .html file for th…

---

## [I built ThreeJSON — a JSON-driven declarative scene runtime for Three.js. Does this abstraction make sense?](https://discourse.threejs.org/t/i-built-threejson-a-json-driven-declarative-scene-runtime-for-three-js-does-this-abstraction-make-sense/92662)

<div class="topic-metadata">

**Author:** [@tianhehechu2017](https://discourse.threejs.org/u/tianhehechu2017)\
**Replies:** 16\
**Last updated:** [July 12, 2026, 11:18pm UTC](https://discourse.threejs.org/t/i-built-threejson-a-json-driven-declarative-scene-runtime-for-three-js-does-this-abstraction-make-sense/92662 "2026-07-12T23:18:00Z")

</div>

Hi everyone, I’ve been working on an open-source project called ThreeJSON, and I recently released its first alpha version. ThreeJSON is a JSON-driven declarative scene runtime for Three.js. The project started from a …

---

## [A central library of my Three.js demos (and two bonus games)](https://discourse.threejs.org/t/a-central-library-of-my-three-js-demos-and-two-bonus-games/91431)

<div class="topic-metadata">

**Author:** [@red-reddington](https://discourse.threejs.org/u/red-reddington)\
**Replies:** 0\
**Last updated:** [May 7, 2026, 4:19pm UTC](https://discourse.threejs.org/t/a-central-library-of-my-three-js-demos-and-two-bonus-games/91431 "2026-05-07T16:19:16Z")

</div>

Hey everyone, I’ve shared a number of Three.js demos here on the forum, usually one at a time as I finished them. I’ve been meaning to organize everything properly, so I finally put together a clean, browsable library o…

---

## [Three.js Examples Are Amazing](https://discourse.threejs.org/t/three-js-examples-are-amazing/90830)

<div class="topic-metadata">

**Author:** [@robotbobby](https://discourse.threejs.org/u/robotbobby)\
**Replies:** 3\
**Last updated:** [April 10, 2026, 11:30pm UTC](https://discourse.threejs.org/t/three-js-examples-are-amazing/90830 "2026-04-10T23:30:49Z")

</div>

---

## [Collection of examples from discourse.threejs.org](https://discourse.threejs.org/t/collection-of-examples-from-discourse-threejs-org/4315)

<div class="topic-metadata">

**Author:** [@hofk](https://discourse.threejs.org/u/hofk)\
**Replies:** 57\
**Last updated:** [January 1, 2026, 12:19pm UTC](https://discourse.threejs.org/t/collection-of-examples-from-discourse-threejs-org/4315 "2026-01-01T12:19:40Z")

</div>

The answers to some questions contain some very interesting and instructive basic examples. These are difficult to find in the large number of questions on discourse.There are also good examples in resources and showcas…

---

## [Three.js examples playground](https://discourse.threejs.org/t/three-js-examples-playground/85652)

<div class="topic-metadata">

**Author:** [@linbingquan](https://discourse.threejs.org/u/linbingquan)\
**Replies:** 4\
**Last updated:** [August 4, 2025, 4:18pm UTC](https://discourse.threejs.org/t/three-js-examples-playground/85652 "2025-08-04T16:18:31Z")

</div>

I make a three.js examples online editor. Welcome to use it. Link: three.js - playground

---

## [Live Code Editor for Examples](https://discourse.threejs.org/t/live-code-editor-for-examples/84383)

<div class="topic-metadata">

**Author:** [@XinWen](https://discourse.threejs.org/u/XinWen)\
**Replies:** 4\
**Last updated:** [July 1, 2025, 8:10am UTC](https://discourse.threejs.org/t/live-code-editor-for-examples/84383 "2025-07-01T08:10:48Z")

</div>

Hi all, I’m putting together a small script that adds a live code editor to the Three.js examples. It also includes some basic type info for THREE.js, so you get a bit of autocomplete and inline docs. Let me know wha…

---

## [Currently, does Threejs fully support the webgpu API?](https://discourse.threejs.org/t/currently-does-threejs-fully-support-the-webgpu-api/52592)

<div class="topic-metadata">

**Author:** [@Liuzr](https://discourse.threejs.org/u/Liuzr)\
**Replies:** 14\
**Last updated:** [May 25, 2025, 11:02pm UTC](https://discourse.threejs.org/t/currently-does-threejs-fully-support-the-webgpu-api/52592 "2025-05-25T23:02:55Z")

</div>

1.Currently, does Threejs fully support the webgpu API? 2.When will the development documents for integrating Threejs with WebGPU be released? 3.What are the plans and arrangements? Please reply, wait online，Thank you…

---

## [Coordinates of cursor's pointer not in the middle of the box](https://discourse.threejs.org/t/coordinates-of-cursors-pointer-not-in-the-middle-of-the-box/82814)

<div class="topic-metadata">

**Author:** [@feelivn](https://discourse.threejs.org/u/feelivn)\
**Replies:** 5\
**Last updated:** [May 20, 2025, 7:52am UTC](https://discourse.threejs.org/t/coordinates-of-cursors-pointer-not-in-the-middle-of-the-box/82814 "2025-05-20T07:52:56Z")

</div>

Hi everyone! I am learning and analyzing examples of three.js site. Im looking at this (three.js examples) example. The red box appears with function named “onPointerMove”, and the cube places not in the middle of curso…

---

## [How to Contribute Examples to the Three.js Website?](https://discourse.threejs.org/t/how-to-contribute-examples-to-the-three-js-website/82090)

<div class="topic-metadata">

**Author:** [@wildy13](https://discourse.threejs.org/u/wildy13)\
**Replies:** 8\
**Last updated:** [May 8, 2025, 2:05am UTC](https://discourse.threejs.org/t/how-to-contribute-examples-to-the-three-js-website/82090 "2025-05-08T02:05:36Z")

</div>

Hello, I’m new to contributing to Three.js examples and I’m wondering if the project I’ve developed is suitable for submission to the official Three.js website (threejs.org). I created a demo using WebGPU, keyboard inpu…

---

## [Sky Shader example](https://discourse.threejs.org/t/sky-shader-example/13653)

<div class="topic-metadata">

**Author:** [@Fluqz](https://discourse.threejs.org/u/Fluqz)\
**Replies:** 4\
**Last updated:** [December 22, 2023, 7:01am UTC](https://discourse.threejs.org/t/sky-shader-example/13653 "2023-12-22T07:01:32Z")

</div>

Hey, im trying to implement the Sky Shader example, but I get a black screen. This is what I implement. I dont need a sun, or is it necessary? I set my camera.far very high this.sky = new Sky() this.sky.scale.setScalar(…

---

## [Can official threejs examples have a live code editing?](https://discourse.threejs.org/t/can-official-threejs-examples-have-a-live-code-editing/58816)

<div class="topic-metadata">

**Author:** [@Neosoulink](https://discourse.threejs.org/u/Neosoulink)\
**Replies:** 14\
**Last updated:** [December 17, 2023, 4:20pm UTC](https://discourse.threejs.org/t/can-official-threejs-examples-have-a-live-code-editing/58816 "2023-12-17T16:20:09Z")

</div>

Like all of us (I hope), I was browsing officials’ ThreeJs examples and at some point, I wanted to test the part I was interested in. But going on Github and trying to copy codes and past them locally just to test a sma…

---

## [Example WebGL / materials in LineMaterials does not work](https://discourse.threejs.org/t/example-webgl-materials-in-linematerials-does-not-work/52632)

<div class="topic-metadata">

**Author:** [@Boris\_Bek](https://discourse.threejs.org/u/Boris_Bek)\
**Replies:** 2\
**Last updated:** [June 9, 2023, 10:08pm UTC](https://discourse.threejs.org/t/example-webgl-materials-in-linematerials-does-not-work/52632 "2023-06-09T22:08:34Z")

</div>

WebGL / materials this link does not show anything maybe it needs to be removed? @Mugen87

---

## [GPU interactive cubes broken?](https://discourse.threejs.org/t/gpu-interactive-cubes-broken/52044)

<div class="topic-metadata">

**Author:** [@jrjdavidson](https://discourse.threejs.org/u/jrjdavidson)\
**Replies:** 2\
**Last updated:** [May 26, 2023, 10:56am UTC](https://discourse.threejs.org/t/gpu-interactive-cubes-broken/52044 "2023-05-26T10:56:09Z")

</div>

is the gpu interactive cubes example broken for anyone else? it seems to highlight the wrong cube https://threejs.org/examples/#webgl\_interactive\_cubes\_gpu

---

## [Examples games\_fps can have a third -person game perspective version?](https://discourse.threejs.org/t/examples-games-fps-can-have-a-third-person-game-perspective-version/44159)

<div class="topic-metadata">

**Author:** [@seanin](https://discourse.threejs.org/u/seanin)\
**Replies:** 1\
**Last updated:** [May 9, 2023, 6:37am UTC](https://discourse.threejs.org/t/examples-games-fps-can-have-a-third-person-game-perspective-version/44159 "2023-05-09T06:37:19Z")

</div>

three.js examples (threejs.org) This case can have a third -person game perspective version ?

---

## [Three.JS Minecraft Example Explanation Pleaset](https://discourse.threejs.org/t/three-js-minecraft-example-explanation-pleaset/49050)

<div class="topic-metadata">

**Author:** [@TacoError](https://discourse.threejs.org/u/TacoError)\
**Replies:** 2\
**Last updated:** [March 13, 2023, 11:42pm UTC](https://discourse.threejs.org/t/three-js-minecraft-example-explanation-pleaset/49050 "2023-03-13T23:42:38Z")

</div>

In this area, I understand how the geometry and putting it together works, I am just confused on how the UV mapping works. Could someone please explain, or direct me to a forum post or something where I can learn how the…

---

## [Mistake in the CSG example](https://discourse.threejs.org/t/mistake-in-the-csg-example/47776)

<div class="topic-metadata">

**Author:** [@oldsegotia](https://discourse.threejs.org/u/oldsegotia)\
**Replies:** 1\
**Last updated:** [February 14, 2023, 2:43pm UTC](https://discourse.threejs.org/t/mistake-in-the-csg-example/47776 "2023-02-14T14:43:37Z")

</div>

I noticed a mistake earlier in the code for the CSG example: https://github.com/mrdoob/three.js/blob/4503ef10b81a00f5c6c64fe9a856881ee31fe6a3/examples/webgl\_geometry\_csg.html This line: renderer.shadowMap.type = THREE.…

---

## [Webgl\_read\_float\_buffer example didn't work on Android](https://discourse.threejs.org/t/webgl-read-float-buffer-example-didnt-work-on-android/392)

<div class="topic-metadata">

**Author:** [@shilin](https://discourse.threejs.org/u/shilin)\
**Replies:** 6\
**Last updated:** [January 7, 2023, 9:51am UTC](https://discourse.threejs.org/t/webgl-read-float-buffer-example-didnt-work-on-android/392 "2023-01-07T09:51:22Z")

</div>

webgl\_read\_float\_buffer example didn't work on Android using Mozilla.

---

## [Cannot recreate DOF2 example  shader  general](https://discourse.threejs.org/t/cannot-recreate-dof2-example-shader-general/43043)

<div class="topic-metadata">

**Author:** [@Cecile-Lebleu](https://discourse.threejs.org/u/Cecile-Lebleu)\
**Replies:** 0\
**Last updated:** [September 29, 2022, 12:23am UTC](https://discourse.threejs.org/t/cannot-recreate-dof2-example-shader-general/43043 "2022-09-29T00:23:03Z")

</div>

Hi! I’m trying to use a similar approach as the DOF2 example for a project. three.js examples However, the postprocessing doesn’t work — the screen looks black. I copied the code and files from the original example li…

---

## [WebGL Portal Example Error](https://discourse.threejs.org/t/webgl-portal-example-error/38427)

<div class="topic-metadata">

**Author:** [@Refr3sh](https://discourse.threejs.org/u/Refr3sh)\
**Replies:** 0\
**Last updated:** [May 23, 2022, 1:02am UTC](https://discourse.threejs.org/t/webgl-portal-example-error/38427 "2022-05-23T01:02:09Z")

</div>

Im trying to make a Portal class out of the threejs example: https://threejs.org/examples/?q=portal#webgl\_portal But im getting some errors that Im not understanding. This is my class class Portal{ constructor(si…

---

## [Use importmap for paths in examples/jsm/](https://discourse.threejs.org/t/use-importmap-for-paths-in-examples-jsm/37354)

<div class="topic-metadata">

**Author:** [@arodic](https://discourse.threejs.org/u/arodic)\
**Replies:** 2\
**Last updated:** [April 22, 2022, 4:48pm UTC](https://discourse.threejs.org/t/use-importmap-for-paths-in-examples-jsm/37354 "2022-04-22T16:48:01Z")

</div>

Is there any way to use importmap to map all paths in examples/jsm? For example, in my typescript project I have: import { WebGLRenderer } from 'three'; import { EffectComposer } from 'three/examples/jsm/postprocessing…

---

## [Some examples broken in Firefox?](https://discourse.threejs.org/t/some-examples-broken-in-firefox/34838)

<div class="topic-metadata">

**Author:** [@trusktr](https://discourse.threejs.org/u/trusktr)\
**Replies:** 3\
**Last updated:** [April 15, 2022, 6:06pm UTC](https://discourse.threejs.org/t/some-examples-broken-in-firefox/34838 "2022-04-15T18:06:08Z")

</div>

Some examples give me an error like the following in Firefox: Uncaught TypeError: Error resolving module specifier “three”. Relative module specifiers must start with “./”, “../” or “/”. This is one example, among othe…

---

## [BUG: Import statements in example/jsm examples are broken](https://discourse.threejs.org/t/bug-import-statements-in-example-jsm-examples-are-broken/34871)

<div class="topic-metadata">

**Author:** [@ErrorBot1122](https://discourse.threejs.org/u/ErrorBot1122)\
**Replies:** 2\
**Last updated:** [February 15, 2022, 12:18am UTC](https://discourse.threejs.org/t/bug-import-statements-in-example-jsm-examples-are-broken/34871 "2022-02-15T00:18:40Z")

</div>

There is a wired bug where if you use the example/jsm modules as a standalone with/without three.module.js it shows this error: TypeError: Failed to resolve module specifier "three". Relative references must start with …

---

## [Examples HTMLMesh dispose texture](https://discourse.threejs.org/t/examples-htmlmesh-dispose-texture/34040)

<div class="topic-metadata">

**Author:** [@Fluqz](https://discourse.threejs.org/u/Fluqz)\
**Replies:** 2\
**Last updated:** [January 25, 2022, 4:34pm UTC](https://discourse.threejs.org/t/examples-htmlmesh-dispose-texture/34040 "2022-01-25T16:34:11Z")

</div>

Hey! Im trying out the HTMLMesh from the VR Example for my project. I noticed heavy lags, after instanciating multiple meshes. Im trying to dispose the HTMLMesh, because I only need them temporarily. When disposing the…

---

## [Three + examples import via CDN](https://discourse.threejs.org/t/three-examples-import-via-cdn/28966)

<div class="topic-metadata">

**Author:** [@papukweh](https://discourse.threejs.org/u/papukweh)\
**Replies:** 1\
**Last updated:** [August 16, 2021, 10:05pm UTC](https://discourse.threejs.org/t/three-examples-import-via-cdn/28966 "2021-08-16T22:05:44Z")

</div>

Hello! I have a React application bundled with Webpack and am trying to load threejs from a CDN on runtime in order to decrease bundle sizes. So far my solution has been to add: externals: { three: 'THREE' } on my …

---

## [How to import classes from three/examples/jsm in a React Typescript app?](https://discourse.threejs.org/t/how-to-import-classes-from-three-examples-jsm-in-a-react-typescript-app/27986)

<div class="topic-metadata">

**Author:** [@mrChernicharo](https://discourse.threejs.org/u/mrChernicharo)\
**Replies:** 3\
**Last updated:** [July 13, 2021, 4:43pm UTC](https://discourse.threejs.org/t/how-to-import-classes-from-three-examples-jsm-in-a-react-typescript-app/27986 "2021-07-13T16:43:58Z")

</div>

I recently cloned the code of a very cool mineraft game built with react and three-fiber. I’m currently trying to transition the original js code into typescript but I’m failing miserably to make the compiler undertand …

---

## [WebGL interactive voxelpainter size cubes](https://discourse.threejs.org/t/webgl-interactive-voxelpainter-size-cubes/27209)

<div class="topic-metadata">

**Author:** [@kanopa](https://discourse.threejs.org/u/kanopa)\
**Replies:** 15\
**Last updated:** [July 1, 2021, 10:25am UTC](https://discourse.threejs.org/t/webgl-interactive-voxelpainter-size-cubes/27209 "2021-07-01T10:25:59Z")

</div>

Hello, when I change the size of the cube from 50 to 1, the cube starts to position itself incorrectly Changed lines const gridHelper = new THREE.GridHelper( 100, 100 ); const geometry = new THREE.PlaneGeometry( 100, 1…

---

## [Plan for "example code"](https://discourse.threejs.org/t/plan-for-example-code/25603)

<div class="topic-metadata">

**Author:** [@alecmce](https://discourse.threejs.org/u/alecmce)\
**Replies:** 2\
**Last updated:** [April 23, 2021, 12:32pm UTC](https://discourse.threejs.org/t/plan-for-example-code/25603 "2021-04-23T12:32:14Z")

</div>

It is interesting (and very helpful!) to see we can pull in “examples” like this in our project without any webpack changes: import { EffectComposer } from 'three/examples/jsm/postprocessing/EffectComposer' import { Ren…

---

## [Where'd the Minecraft AO example go?](https://discourse.threejs.org/t/whered-the-minecraft-ao-example-go/24103)

<div class="topic-metadata">

**Author:** [@tussiez](https://discourse.threejs.org/u/tussiez)\
**Replies:** 2\
**Last updated:** [March 6, 2021, 12:37pm UTC](https://discourse.threejs.org/t/whered-the-minecraft-ao-example-go/24103 "2021-03-06T12:37:36Z")

</div>

I was looking into “baking” ambient occlusion into my voxel geometry. I remember seeing an Ambient Occlusion version of the Minecraft example on the Three.js website, but no longer see it. I was planning to try and use? …

---

## [Angular template for Three.js](https://discourse.threejs.org/t/angular-template-for-three-js/6581)

<div class="topic-metadata">

**Author:** [@makimenko](https://discourse.threejs.org/u/makimenko)\
**Replies:** 2\
**Last updated:** [March 2, 2021, 4:10am UTC](https://discourse.threejs.org/t/angular-template-for-three-js/6581 "2021-03-02T04:10:58Z")

</div>

Sample template of Angular project with Three.js: Simplify new web project development with Angular and Three.js This template project can be quickly used as base instead of wasting hours of going through building inst…

[Next page](https://discourse.threejs.org/tag/examples/29.md?match_all_tags=true&page=1&tags%5B%5D=examples)
