Key points
- Three.js draws 3D in the browser through WebGL. React Three Fiber brings the scene into React apps.
- If a product only needs to spin and show up in AR, a ready-made viewer often does the job.
- Agree a budget for file size and triangles before development starts, and measure it on a mid-range phone.
- Text and options belong in the HTML next to the canvas. That is where Google and screen readers look.
What is Three.js good for?
Three.js is a JavaScript library that renders 3D graphics in the browser through WebGL. Nobody installs anything. Your customer opens the product page and spins the armchair with a thumb.
It suits projects like these:
- Product configurators that check rules and calculate prices
- 3D viewers on product pages, often with an AR button
- Interactive 3D websites where a scene moves as you scroll
- Planners where customers arrange modules on a floor plan
Three.js, Babylon.js or a ready-made viewer?
A ready-made viewer is enough more often than people expect. If a product only needs to turn and appear in the room through AR, a web component such as Google's model-viewer covers it. One GLB file, one HTML tag, some care with light and camera.
Three.js is deliberately lean. It handles the camera, lights, materials and model loading. Interface and physics come from its ecosystem or from your own code. With React Three Fiber, or R3F, the scene becomes React components and shares its state with the basket and the enquiry form. If your site already runs on React or Next.js, that's the shortest route.
Babylon.js is a fuller engine with its own inspector and GUI system, and it takes backward compatibility seriously. If the app behaves more like a game or a simulation, it's a strong choice. For configurators and product viewers we mostly pick Three.js with React Three Fiber, because the scene has to work closely with the shop.
How much 3D can a phone handle?
Picture your customer on a train with a three-year-old phone. That's who we plan for. Before development starts we agree a budget covering triangles per scene, the number and size of textures, and the megabytes until the first frame. We measure it on a mid-range device over mobile data. These tools keep it in check:
- Compress geometry with Draco or Meshopt. The browser unpacks it while loading.
- Ship textures as KTX2. They stay compressed in graphics memory. A JPEG gets decoded there and takes up about 64 MB as a 4K texture.
- Merge parts and share materials so the phone handles fewer draw calls.
- Load the scene only when it scrolls into view or someone taps “View in 3D”. Until then, a photo holds the spot.
- Cap the pixel ratio on high-density screens. Hardly anyone sees the difference. The battery does.
Live examples
Try two product configurators
Change the roof width on Main Pergola. On Main Zelt, switch between tent ranges and try different colours.
Should you be thinking about WebGPU yet?
WebGPU is the successor to WebGL. It talks to the graphics chip through modern interfaces and can run general calculations on it with compute shaders. Scenes with huge numbers of objects, particles or simulations gain the most.
The major browsers have switched WebGPU on, though not yet on every device. Three.js ships a WebGPU renderer that falls back to WebGL 2 where WebGPU is missing. That's why we write custom shaders in TSL, the Three.js shading language, which compiles for both. For a single product on screen, WebGL does the job today. The upgrade path stays open anyway.
Can Google and screen readers see what's in the canvas?
No. To both, a canvas is a surface without text. So the product name and description go into the HTML next to it, along with specs and price.
Options are real buttons and select fields with labels, and they work with a keyboard. The 3D view follows whatever is selected in the HTML. A still image with alt text holds the place while the scene loads. Visitors who have turned on reduced motion in their system settings get no automatic camera moves. And because the scene loads after the visible content, Largest Contentful Paint stays fast, one of the loading metrics Google looks at.
What should you ask a Three.js developer before hiring?
Open their live work on your own phone. A video only shows what ran on the developer's machine. Then ask these questions:
- Who creates the 3D models, and who prepares them for the web?
- What is the budget for file size and triangles, and how is it measured?
- How will your team add a new colour without a developer?
- What do devices without WebGL get to see?
- How are updates handled? Three.js changes its API from release to release.
- Do the source code and the models belong to you at the end?
Prototype first, then the full build
We start with a clickable prototype. It shows one real model made from your data, with the options that matter most, and you test it on your own phone. That's where you see whether the materials work and the loading time holds. You release the larger budget only once the prototype has convinced you. The source code and documentation are yours afterwards.
Frequently asked questions
What is the difference between WebGL and Three.js?
WebGL is the browser's interface to the graphics chip. Three.js sits on top of it and handles the camera, lights, materials and the loading of glTF models. Writing raw WebGL only pays off in special cases.
Do we need React Three Fiber, or is Three.js enough?
React Three Fiber is a layer over Three.js for React projects. If your site runs on React or Next.js, R3F saves a lot of glue code between the scene and the interface. For a site without React, plain Three.js is the leaner choice.
How much does Three.js development cost?
Three.js is free under the MIT licence, so there are no licence fees. The effort depends on the 3D models, the rules of your product and the connection to your shop or ERP. For configurators, we describe the five cost drivers in a separate guide.