three.js

The cross-browser JavaScript 3D library that renders scenes through WebGL and WebGPU behind one unified, node-based shading API.

Library
npm
v0.185.1
115,194stars
MIT License

Repository Health

Pre-computed score based on development activity, maintenance, community, maturity, and trend momentum.How we score it →
98/100Excellent
Development Activity100
Maintenance96
Community96
Maturity60
Momentum40

Technical Analysis

AI-assessed by reading the actual repository — architecture, code quality, innovation, and documentation.How we score it →
86/100Excellent
Architecture90
Code Quality88
Innovation85
Learning Curve80

three.js is the library most JavaScript developers reach for when they need real-time 3D (or 2D) graphics in a browser tab, no plugins required. It wraps the low-level WebGL and WebGPU APIs in a coherent scene graph — cameras, lights, geometries, materials, and meshes composed as objects rather than raw draw calls — so building a working scene takes a dozen lines instead of hundreds of lines of shader boilerplate.

Started by Ricardo Cabello (mrdoob) in 2010, the project has grown into the de facto standard for web-based 3D: it powers everything from product configurators and data visualizations to WebXR experiences and generative art, and ships monthly releases (r-numbered) with a large addon ecosystem (loaders, controls, post-processing, physics bridges) distributed alongside the core.

The modern core is built around TSL (Three.js Shading Language), a JavaScript-authored node system that compiles down to either GLSL (WebGL) or WGSL (WebGPU) from the same material graph — letting projects target both renderers, and eventually compute shaders, without hand-writing two shader languages.

What You Get

  • A full scene graph (Object3D/Scene/Group hierarchy) with transforms, raycasting, and frustum culling handled for you
  • Dual-backend rendering — WebGLRenderer and WebGPURenderer share the same TSL-authored materials so a project can target either backend
  • TSL (Three.js Shading Language), a JS node-graph API for authoring shaders that compiles to GLSL or WGSL without hand-writing either
  • A large catalog of geometries, standard/physical materials (PBR), lights, and loaders (glTF, Draco, KTX2, OBJ, and more) shipped as addons in examples/jsm
  • Built-in animation system (AnimationMixer, keyframe tracks, skeletal/morph-target animation) and a WebXR integration for VR/AR
  • 600+ runnable examples and an extensive manual/docs site (threejs.org) covering every module in the public API

Common Use Cases

  • Interactive product configurators and 3D e-commerce viewers rendered directly in the browser
  • Data and scientific visualization that needs true 3D perspective, point clouds, or volumetric rendering
  • WebXR (VR/AR) experiences that need a scene graph rather than raw WebXR device API calls
  • Generative art, creative-coding, and shader-driven visual experiments authored through TSL
  • Game-like interactive experiences and 3D UI elements embedded in otherwise conventional web apps

Under The Hood

Architecture At the center of three.js is a classic scene-graph: Object3D (src/core/Object3D.js, ~1700 lines) provides the transform hierarchy, matrix updates, and traversal that every Scene, Mesh, Camera, and Light inherits from, while Three.Core.js re-exports the renderer-agnostic pieces (math, core, geometries, materials, loaders) separately from Three.js, which layers the concrete WebGLRenderer on top — a separation that lets Three.WebGPU.js swap in the WebGPU backend against the same core object model. Rendering itself is split into a large src/renderers/ tree with parallel webgl/ and webgpu/ subfolders sharing a common/ layer, and a src/nodes/ tree (accessors, core, display, lighting, math, procedural, tsl) that implements the node-graph compiler feeding both backends — the architecture’s central bet is that authoring shaders as composable node graphs, not backend-specific shader strings, is what lets one material definition target two entirely different graphics APIs. What would break if that abstraction changed: virtually every downstream addon in examples/jsm, since materials, post-processing passes, and loaders all consume the node system’s public surface.

Tech Stack Pure JavaScript (ES modules, no required TypeScript, though .d.ts-adjacent type packages exist separately) with zero runtime dependencies — the entire 3D math (src/math/), scene graph, and renderers are hand-rolled rather than delegated to third-party libraries. The build pipeline uses Rollup (utils/build/rollup.config.js) to produce ESM and CJS bundles (build/three.module.js, build/three.cjs, plus a dedicated build/three.webgpu.js and build/three.tsl.js), and ESLint (flat config, eslint.config.js) enforces style across src, examples, editor, manual, test, and utils as separate lint targets. Distribution is npm-native (package name three) with addons (loaders, controls, postprocessing) shipped as ES modules under examples/jsm/ rather than bundled into the core, keeping the core package lean while still being installable from the same package.

Code Quality Testing uses QUnit across 264 unit test files under test/unit/src/ (mirroring the src/ module layout one-for-one, e.g. test/unit/src/core/BufferAttribute.tests.js) plus addon tests under test/unit/addons/, run headlessly through Puppeteer (test/unit/puppeteer.unit.js); there’s a separate end-to-end visual-regression suite (test/e2e/) that renders the example gallery and diffs screenshots, plus a tree-shaking test (test/rollup.treeshake.config.js) that verifies unused modules are actually eliminated from bundles. Error handling favors explicit throw/console.error at API boundaries (e.g. BufferAttribute rejecting non-typed-array input) over silent failure, naming is consistent and PascalCase-for-classes throughout, and CI (.github/workflows/ci.yml, plus dedicated CodeQL, bundle-size-report, and protected-folders workflows) runs lint, unit, and e2e suites on every change — a maturity level consistent with a 15-year-old project maintained by a large, active contributor base (2,554 contributors).

API Design The public API optimizes for the “twelve lines to a rendered cube” experience shown in its own README: new THREE.Scene(), new THREE.PerspectiveCamera(), new THREE.Mesh(geometry, material), renderer.render(scene, camera) — a handful of composable primitives rather than a large configuration object. TSL extends that ergonomics story into shader authoring: instead of writing GLSL/WGSL strings, developers compose small JS functions (vec3(), mul(), texture(), etc.) that read like normal JavaScript and get compiled per-backend, which meaningfully lowers the barrier to custom materials compared to hand-written shader code. The tradeoff is API surface size — the full module catalog (geometries, materials, loaders, nodes, controls) is large, and the migration guide wiki exists specifically because the r-numbered release cadence (roughly monthly) does introduce breaking changes across the 100+ documented releases in the project’s history.

Used by 25 apps in this directory

TypeScript
92%
GPL 3.0

Blinko

Knowledge Management · Note Taking

10,992

A self-hosted, AI-powered card note-taking tool that lets you capture fleeting thoughts instantly and retrieve them with natural language search.

View details
80
Repo Health
69
Technical
63
Dependency
Built with
TypeScript92%
Updated 1 weeks ago
Rust
67%
MIT

Bun

Developer Tools

95,895

An all-in-one JavaScript and TypeScript toolkit — one Rust-and-JavaScriptCore binary that replaces Node.js, npm, a bundler, and a test runner with faster equivalents.

View details
92
Repo Health
91
Technical
64
Dependency
Built with
Rust67%
C++19%
Updated yesterday
TypeScript
81%
Other

Directus

CMS · Low Code Platforms

37,783

Connect any SQL database and get instant REST and GraphQL APIs, a visual management Studio, and a native MCP server for AI agents — free for most organizations.

View details
92
Repo Health
82
Technical
76
Dependency
Built with
TypeScript81%
Vue18%
Updated 3 days ago
TypeScript
54%
MIT

FormBee

Forms Surveys

770

A self-hostable form backend that accepts HTML form submissions and routes them to email, Telegram, Discord, webhooks, and automation platforms — without writing any server-side code.

View details
29
Repo Health
48
Technical
70
Dependency
Built with
TypeScript54%
SCSS25%
HTML19%
Updated 1 years ago
JavaScript
64%
Other

GDevelop

Developer Tools · Game Development · Design Tools

26,276

No-code, open-source game engine for building 2D, 3D and multiplayer games — publish to iOS, Android, Steam and the web.

View details
93
Repo Health
82
Technical
61
Dependency
Built with
JavaScript64%
C++23%
TypeScript12%
Updated yesterday
Ruby
67%
Other

GitLab

Devops · Developer Tools

24,552

The complete DevOps platform that unifies Git hosting, CI/CD, issue tracking, and security scanning into a single self-hostable application.

View details
87
Repo Health
86
Technical
68
Dependency
Built with
Ruby67%
JavaScript20%
Updated today
TypeScript
71%
Other

highlight.io

Developer Tools · Analytics · Monitoring

9,372

Open-source full-stack monitoring that unifies session replay, error tracking, logging, and distributed tracing so you can stop context-switching between tools.

View details
69
Repo Health
78
Technical
65
Dependency
Built with
TypeScript71%
Go16%
Updated 2 weeks ago
TypeScript
77%
MIT

Hippo

AI Agents

740

A biologically-inspired memory layer for AI coding agents — memories decay by default and strengthen through use, modeled on the hippocampus, with zero runtime dependencies and a SQLite backbone.

View details
76
Repo Health
71
Technical
81
Dependency
Built with
TypeScript77%
Updated yesterday
Rust
47%
MIT

Kuku

Note Taking

219

A local-first, open-source Markdown knowledge workspace for macOS — plain files, personal wiki and Second Brain workflows, AI-assisted diffs, and encrypted sync, built as an Obsidian alternative.

View details
81
Repo Health
67
Technical
67
Dependency
Built with
Rust47%
TypeScript40%
Updated yesterday

Join founders buildingwith open source

Opinionated takes, migration guides, cost-saving tips, and insights from the open source ecosystem.

Subscribe on Substack
Join 750+ subscribers

Search