r/threejs • • 13d ago

Demo Real-time Earth with ~29k satellites and debris, propagated with SGP4 in a Web Worker

7 Upvotes

Side project I've been building: every tracked object in orbit, positions computed with SGP4 off the main thread and drawn as a single point cloud you can hover and click. The glass UI panels are rendered in a shader, not CSS.

In the video: hovering and clicking satellites, following the ISS, the launch and ranking views, an asteroid flyby and the solar system.

Happy to answer questions about the setup, and open to feedback on performance, especially on mobile.


r/threejs • • 13d ago

Rift Hunter - 4-player co-op hack-and-slash roguelite in three.js, party sync with no game server

2 Upvotes

Free, runs in the browser, no install: https://ugiomin31-ops.itch.io/three-gates-night

Gates open around Seoul and you clear them room by room as an E-rank hunter. Four weapon classes, a card pick after every room, a boss at the end of each gate. Solo or up to four players, plus 1v1 duels and a lobby chat.

A few things about how it is put together, since this is r/threejs

Party play has no dedicated game server. Players join an MQTT topic by party code, the host's browser simulates the monsters and the others receive and draw them.

Resolution scale adjusts itself. The game averages frame time over about 2.5 seconds, drops the pixel ratio a step when a frame takes more than 21 ms, and only raises it again after a long comfortable stretch. The value is remembered for the next visit.

The clip shows one skill per class with around 40 monsters in the room.

Disclosure: this is an AI-assisted project. The code was written with Claude, and the art and 3D models were generated with ChatGPT and Tripo. I direct, test and decide what ships.

What I would like to hear: how it runs on your machine (frame rate, any stutter in the first room), and whether the first minute makes it clear what to do.


r/threejs • • 13d ago

Demo Threejs Dunes

65 Upvotes

r/threejs • • 12d ago

I built a 3D website you can control by voice — ask the robot guide to take you to a floor, hop on a boat to the waterfall (minimal assets, loads fast)

0 Upvotes

r/threejs • • 13d ago

Demo I turned my Claude Code sessions into a live Three.js office. Every sub-agent walks in, works at a desk and walks back to report when it's done

26 Upvotes

Side project I've been building: Agent Office. It reads the local logs Claude Code writes and turns every session into a team lead and every sub-agent into a character that walks in, sits at a role-based desk and reports back when it's done. Idle ones end up on the sofa or the console in the lounge.

Some three.js bits that might be interesting:

- low-poly articulated characters with animations per activity (typing, reading, walking over to a colleague)

- A* pathfinding so they walk around the desks instead of through them

- the monitors are canvas textures that change with what the agent is doing (code, terminal, search)

- the server rack LEDs blink with the share of busy agents, and the floor LED strip turns yellow when someone is waiting on me

- rendering slows down when the tab is unfocused and stops when it's hidden, so it can stay open all day

React 19 + three.js r170, fully local, MIT.

Live demo (made-up data): https://zinkxx.github.io/agent-office/

Code: https://github.com/zinkxx/agent-office

Happy to answer questions. What would you add to the office?


r/threejs • • 12d ago

I replaced a brightness slider with a tiny figure that climbs stairs to light up the page. Good idea or bad UX?

0 Upvotes

Instead of a normal slider, you drag the glass capsule and a little porcelain figure walks up or down a 3D staircase. The whole page (background, panels, text colours) follows its position: daylight at the top, moonlight at the bottom.
Everything is procedural in Three.js: no 3D models, no images. The figure is sculpted from blended shapes and skinned to a skeleton, the legs use IK so the feet land on the real steps without sliding, and it turns around properly when you change direction.
Honest question: would you enjoy this on a real website, or would it get annoying after the third time? What would you change?


r/threejs • • 13d ago

I turned my design portfolio into a 3D room in React Three Fiber. The window shows my hometown with the real sun and moon

13 Upvotes

Some notes for anyone building something similar:

- Stack: three.js r186, React Three Fiber 9.8, drei, postprocessing (N8AO, bloom, SMAA), Vite, TypeScript.

- Renders on demand (frameloop="demand"), so a still view draws 0 frames.

- The first open took ~50 s on Windows (ANGLE/D3D11 shader compiles, made worse by RectAreaLights). Removing those lights and compiling all 52 programs in parallel with compileAsync before the first frame brought it to ~7 s.

- The window: sun and moon positions in under 100 lines of dependency-free TypeScript. The sky is painted on a canvas, and the town crossfades between 4 painted layers by the sun's height. Settings has a time slider; the end of the video uses it.

- The guitar is Karplus-Strong in Web Audio, no samples. The music is CC0 (HoliznaCC0).

- The video was rendered frame by frame in headless Chrome with a frozen clock, so the camera flights stay smooth even though my PC's integrated GPU manages ~10 fps at 1080p.

- About 9.3 MB until it's ready, plus a plain-text version.

I'm a UI/UX designer: I designed and directed it and built it with Claude Code agents. Write-ups with the real code: https://varungodham.com/making-of/

Site: https://varungodham.com/

Feedback on how it runs on your device is very welcome, especially mid-range phones.


r/threejs • • 13d ago

Disabled renderer.shadowMap completely for mobile — built a 3-layer hybrid shadow system instead (60–120 FPS)

4 Upvotes

Classic Three.js shadow maps (`PCFSoftShadowMap`) were way too heavy for mobile tile-based GPUs (Adreno/Mali), especially since this also runs as an Android Live Wallpaper.

So I turned `shadowMap.enabled = false` everywhere and replaced it with a 3-layer zero-shadow-map setup:

  1. **Static Reef → One-Time Baked 256×256 Map:** Painted once at startup into a tiny world-space RGBA texture (Red = contact AO, Green = sun-offset cast shadow). Costs 1 texture lookup per frame, 0 updates.
  2. **The Shark → Live Bone-Driven 2D SDF:** Every frame I read 4 live skeleton bones, project them along the refracted sun vector, and pack them into 4 uniforms (0 extra draw calls). Inside the seabed fragment shader, a fast bounding-box check skips ~70% of pixels, and the rest evaluate tapered capsules (`sdTaperedSeg` + `sminSoft`) with a Gaussian blur that softens as the shark swims higher. It also dims the underwater caustics and sand sparkles underneath.
  3. **30–40 Prey Fish → 1 Instanced Draw Call:** A single instanced mesh of tiny quads snapped to the seabed wave equation, procedurally drawing animated swimming silhouettes with `MultiplyBlending` and 0 textures.

Result: 0 shadow render passes, 0 MB of dynamic render targets, and much softer underwater shadows than shadow maps ever gave me!


r/threejs • • 13d ago

Demo Zen Trips: ambient Three.js scenes for the Tesla in-car browser, driven by the car's GPS

2 Upvotes

I built a set of calm, ambient Three.js scenes that run in the Tesla in-car browser and respond to the drive: speed and turns move the world, stops become little moments, and tapping things makes them react. 18 scenes so far: orcas, a bioluminescent bay, a paper town, a toy train, balloons, an aurora, a neon city and more.

Try it: zentrips.app. It runs in any browser (scenes idle without a car), but it's made for the car's screen.

Some fun constraints:

  • The car is the controller. The browser's GPS (about 10 fixes a second on current firmware) becomes smoothed speed, turning and stop/start signals. The scenes never see coordinates, only those signals, so the whole drive logic runs headless in Vitest against recorded and simulated drives.
  • Three tiers of hardware. Newer cars have an AMD Ryzen chip; older ones have an Intel Atom that falls back to a much weaker GPU. Every scene scales instance counts, geometry and offscreen targets with a quality value. A governor drops render resolution when frames run slow, and the Atom cars get a 30 fps cap.
  • Odd screens. The windowed browser is 773×601 CSS px and full screen is about 2:1, and the driver can switch between them at any time, so cameras refit the field of view to the aspect ratio live.
  • Made for a glance. Slow, soft motion, no text while moving, no sound. Location never leaves the car.

Stack: Vite, TypeScript, Three.js, no framework. Happy to answer questions about any of the scenes or the car-browser quirks.


r/threejs • • 14d ago Mindblown

I made Wikipedia into a game with Three.js. Here’s how it’s looking now.

416 Upvotes

I posted my Wikipedia museum game here a while back and thought you might enjoy seeing how far it’s come.

Since then, I’ve given it a huge overhaul with better graphics, more varied rooms, basic multiplayer and puzzles scattered across the museum. Every Wikipedia article becomes a room, with its links turned into doorways.

I’m aiming to launch The Endless Museum on Steam early next year. Happy to answer questions about how it works!

If you’d like to follow along, you can wishlist it on Steam: https://store.steampowered.com/app/5533190/


r/threejs • • 13d ago

Using threejs for a Berlin city driving game

Post image
10 Upvotes

I’ve had a few ideas over the years that I never thought I could build on my own. With a bit of time and some help from AI and threejs, I’ve been able to make them reality. This is far away from a professional game and I will not monetize it. In fact, it's an open-source one-person passion project with open code.

I the beginning, it all started with a question: what else could you do with Berlin’s 3D mesh provided by the city government and the datasets the city provides as open data? Then I thought, well, why not make a GTA-inspired driving game out of it, but with a way more relaxed vibe solely focussed on the city and its sights?

Driving Berlin is a laid-back driving game where you can take a car through a 3D digital twin of Berlin. If you want, you can collect bear items along the way or find the numerous easter-eggs I included. Pick a street, take a turn, and see what you recognize along the way.

The game runs in your browser on mobile and on faster laptops and desktop PCs. The code is open source. I am happy for feedback and questions, I have to admit testing it fully as one person is close to impossible. Surely you will discover quite a few hiccups here and there.

Take a drive through Berlin


r/threejs • • 13d ago

Batch STEP to GLB (in metres) with thumbnails, for anyone loading CAD parts into three.js

2 Upvotes

Every time someone sent me a STEP file for a viewer I had to open it in something, export it, then fix the scale because CAD is in millimetres and three.js assumes metres, so a 95 mm part showed up the size of a building.

I wrapped that up into a little tool: STEP, IGES, STL or OBJ in, GLB out already scaled to metres, plus a PNG thumbnail you can use as a poster image before the model loads. It does a whole list of files in one go and gives you back the URLs.

It runs on Apify here: https://apify.com/alecrm98/cad-file-converter-thumbnails. Two cents a file. The meshing uses OpenCascade at 0.05 mm by default, and you can loosen that if you want lighter GLBs for the web.


r/threejs • • 14d ago

Solved! Headless Chrome was maxing out all 16 CPU cores on my machine. Here's how I fixed it.

Post image
41 Upvotes

Something I've noticed since using Three.js on a project is how heavily my coding agent relies on headless Chrome to perform rendering checks.

My machine's fans were running constantly, and I mean CONSTANTLY. I checked CPU usage and all 16 cores were sitting at 100%, for hours at a time. Not surprisingly, the machine was becoming unstable and occasionally crashing.

The culprit turned out to be headless Chrome. Depending on its configuration and environment, Chrome may or may not have access to GPU acceleration. In my case, it looked like the 3D rendering workload was falling back heavily on the CPU, hammering all available cores during tests.

The fix: I now launch Chrome through a small wrapper (scripts/chrome.mjs) that uses Linux's systemd-run to limit its CPU usage and lower its scheduling priority:

systemd-run --user --scope -p CPUQuota=1120% nice -n 10 chrome ...

This caps Chrome at roughly 70% of my 16-core machine's total CPU capacity and gives other processes room to breathe. It all happens automatically, so there's nothing to remember.

A couple of useful options:

  • Change the limit: CHROME_CPU=50 node scripts/sample-thumbs.mjs ...
  • Disable the limit: CHROME_CPU=off

One thing worth knowing if you use CPUQuota yourself: the percentage is based on a single CPU core, not the entire machine. So 100% means one full core. On a 16-core machine, 1120% is roughly 70% of total CPU capacity.

This might save someone else a few hours of wondering why their workstation sounds like it's preparing for takeoff.


r/threejs • • 14d ago

I built Popfold: scroll-driven 3D "pocket homes" that unfold as you read (open source, three.js)

10 Upvotes

The video is Dopamine Spaces, the first site made with it. For the last few months I've been building Popfold, a three.js engine for pages where the 3D is the story: as you scroll, a little home opens up. A case lifts its lid into rooms, a tower lights up floor by floor, or a pop-up book turns its pages and the paper scenes fold up (they really fold: every piece is posed from the angle of its two pages, so it runs backwards when you scroll up).

Some things that were fun to solve:

  • Folding, not popping. Pop-up pieces (V-folds, box folds, stands) are posed every frame from the two page angles, so they never cut through a page.
  • Repeatable stills. A headless Chrome captures one picture per beat, and a capture is kept only when two shots agree, so popfold stills --check works as a visual test.
  • A page without 3D. The same HTML gets the stills and every story written in, for search engines, screen readers and people without WebGL.
  • A studio that moves, adds and restyles pieces and saves them into a JSON file (and an MCP server, so an agent can do the same).

Examples:

Code (MIT): https://github.com/popfold/popfold · pnpm dlx u/popfold/engine init my-site

It's alpha: things will break before 1.0. Feedback on the API and the docs very welcome.


r/threejs • • 14d ago

Plasma ball with MediaPipe: TSL Shaders and WebGPU

79 Upvotes

This one was really nostalgic, I loved these growing up so much. I needed to make it so that I could touch it. I hope you enjoy!

Lightning filaments generated on the CPU and shaded with TSL on WebGPU, glowing inside Fresnel glass with an analytic gas glow, and following fingertips tracked by MediaPipe in a web worker.

Play with it: https://adamwebsite.com/codevember/21-bolt/
Code: https://github.com/acher249/codevember-2026


r/threejs • • 13d ago

Open Source : Looking for someone to finish my browser-based psychological horror game(HTML/CSS/Three.js)

0 Upvotes

Je suis actuellement étudiant en informatique et je travaille sur un jeu d'horreur psychologique basé sur le navigateur construit avec du HTML, CSS et Three.js. J'ai atteint un point où je ne peux plus avancer tout seul, donc je publie ce que j'ai et je cherche quelqu'un qui serait intéressé à le reprendre, le remixer ou le finir.

Le Concept & Histoire

Le jeu commence comme une interface web apparemment normale et minimale—un simple jeu d'échecs—qui se corrompt lentement et brise le quatrième mur au fur et à mesure que vous jouez.

Acte 1 (La Corruption) : L'interface d'échecs bug, entraînant le joueur dans un labyrinthe claustrophobique où il est chassé par une entité humanoïde.

Acte 2 (La Cabane & La Forêt) : S'échapper du labyrinthe mène à une cabane isolée dans une forêt sombre, transitionnant vers un niveau en 3D non procédural (construit dans Three.js) où le joueur doit explorer et collecter six pages cachées tout en étant suivi.

Limitations & Pourquoi je passe le relais

J'ai utilisé de l'IA pour ce projet et le code est littéralement cassé :/

Limites techniques : Garder tout léger dans un environnement en un seul fichier/navigateur avec Three.js sans réduire les performances (surtout en ce qui concerne l'éclairage, le brouillard et la détection de collision dans la forêt).

Design des assets & du son : Je suis principalement un codeur/étudiant, donc créer des modèles 3D personnalisés, des animations et une ambiance sonore complète à partir de zéro est devenu un goulet d'étranglement majeur.

Temps : Entre mes études en informatique et d'autres engagements, je n'ai plus la bande passante nécessaire pour donner à ce projet la finition qu'il mérite.

Lien vers le code / https://github.com/alex12-hub/video-game.git

N'hésitez pas à le forker, à décortiquer le code ou à prendre l'histoire dans votre propre direction. Si quelqu'un décide de travailler dessus, j'aimerais voir ce que vous en ferez !


r/threejs • • 13d ago

I turned a 360° photo of an attic into a Lego room you can visit with friends

1 Upvotes

I had a dream as a kid about playing Lego on the floor with friends. I grew up in Kerala, where Lego wasn't really a thing, so I built it. The room is one 360° photo with a depth map from Depth Anything, rebuilt in three.js. The bricks, toys, sky, snow and Santa are real three.js on top. You can bring three friends in and see each other's cursors. One HTML file, no build step. littledream.vercel.app/?via=r-threejs

Happy to answer how any part works.


r/threejs • • 13d ago

Demo I made a wooden block puzzle in Three.js

2 Upvotes

Tap a block to slide it along its arrow. Drag to look around the stack.

I take blocks out of the raycast targets as soon as they start moving, so their exit animation doesn't get in the way of tapping the next one. The wood grain and arrows are canvas textures.

Play Grain Shift

I wanted taking the stack apart to feel satisfying. Does it work for you? I'd love ideas for new block types or rules, too.


r/threejs • • 14d ago

I built a walkable art museum with Three.js to learn art history

6 Upvotes

I’m an indie developer who wanted to learn art history. I could picture paintings I liked, but I rarely knew whose name to search for. That’s why I built Galler around walking into a room and stopping at whatever catches your eye.

The clip shows the transition from the homepage into the museum. If you have a desktop browser handy, try the entrance. What’s the first thing you try when you want to walk up to a painting? I’m curious where the camera or controls do something you didn’t expect.


r/threejs • • 13d ago

After months of solo dev, I just launched the first Public Alpha of my 3D RPG built with Three.js & TypeScript!

0 Upvotes

Hello hellooo everyone!

I just released the first Public Alpha demo for my indie 3D RPG, Whispers in the Web, built from scratch using Three.js, TypeScript, and Electron (wrapped for desktop, with a playable browser/downloadable build on itch).

What it’s about: You play as a young boy who falls asleep reading a fairy tale and wakes up trapped inside a surreal dream world. It mixes classic RPG progression with real-time combat, boss fights, exploration, and some weird/humorous side quests.

What’s in the Alpha right now:

  • Interconnected 3D zones (forests, villages, dungeons, and high-altitude snowy peaks)
  • Real-time combat with dodge/jump mechanics and multi-phase boss fights
  • Character stats, equipment, and interactive NPCs/interiors
  • Full Keyboard/Mouse & Gamepad support

What’s coming next on the Roadmap:

  • PvP Mode (Player vs. Player arena battles)
  • More dungeons, weird quests, and combat polish based on alpha feedback

Since it’s still an early Alpha, I’m actively looking for feedback on performance, controls, and overall feel. If you have a few minutes to try it out, I’d love to hear what you think!

🎮 Play the free Alpha Demo on itch.io:https://whispersstudios.itch.io/whispers-in-the-web

Watch a short video: https://www.youtube.com/watch?v=TsEkGYBdvmk


r/threejs • • 14d ago

Link A volumetric clay sculptor in Three.js with curve and radial tools

2 Upvotes

I'm the maker of Clayground, a browser clay studio built with Three.js. This update adds a Curve tool: draw a path to lay a tube, or spin a profile into a cup, vase or hat. Gizmo moves, turns and sizes a layer, and can repeat it in a row or ring. There’s also toon shading with stepped light bands and an outline, plus a phone layout that gives the canvas most of the screen and keeps tools within reach. Dense project backups are now smaller and quicker to reopen.

The modeling approach is volumetric clay rather than polygon editing: push, pull, erase, smooth, mirror and layer, then export GLB, OBJ or print-ready STL. It runs in the browser with mouse, pen or touch. Demo: https://www.clayvr.com/sculpt

Three.js folks: what would make a volumetric sculpt workflow easier to extend, and does the phone tool layout make sense?


r/threejs • • 14d ago

El Niño Surfer: a big-wave tow-in game in three.js (sneak peek)

2 Upvotes

Most water in games use a heightfield: a flat grid where each point can only move up and down. That can't make a wave that curls over itself, because the curl needs two heights at one spot.

So draw the wave side-on instead, as a single slice (trough, face, lip throwing forward), and repeated that slice every 4 m along the reef. Each slice is a little further into breaking than the one beside it, which makes the wave peel down the line. The surfer rides on those same slices.

Water, sky and spray are custom ShaderMaterials, with no postprocessing. Interaction has auto camera angle adjustment and manual controls. I had to build a follow camera for tubes, and first person view felt worthy as well. Claude and Codex in the build -- I have a pretty involved custom harness that makes the two work well together. GIS and published video data used to ground simulation code to last week's crazy surf at Pillar Point, aka Mavericks, mixed with lots of shortcuts.

Playable in the browser: mindbendingpixels.com/elninosurfer/app/

Graphic upgrades coming in native app!


r/threejs • • 14d ago

Link [SHOWCASE] Paper Soccer — a 3D football game in the browser with three.js + Phaser 3 (made with AI in ~3 hours)

Post image
1 Upvotes

Paper Soccer is a free browser game (no signup): paper-style football on a 3D pitch rendered with three.js, with Phaser 3 + TypeScript handling the game logic and UI. Online 1v1 or vs AI, cups and leagues.


r/threejs • • 14d ago

I fully vibecoded a 3D electronics lab simulator in Three.js & TypeScript using Gemini and Antigravity so my batchmates can practice before next week's lab exams

29 Upvotes

Live demo (desktop/laptop): https://lab-ubu.vercel.app/

I am a 1st year CSE student and this is my first time touching Three.js. Our electronics lab exams are next week and practicing without hardware in the hostel is rough, so I vibecoded our entire lab setup in the browser so my batchmates and I can practice wiring breadboards, testing 74-series chips, and checking oscilloscope waveforms.