threejs-devtools-mcp
Provides a glTF to React Three Fiber (gltf_to_r3f) conversion tool, enabling translation of glTF models into R3F components.
Provides Puppeteer and Playwright helpers to attach devtools to a browser context, wait for scenes, and call Three.js tools in automated tests.
Integrates with React Three Fiber, enabling live inspection and modification of R3F scenes and generating ready-to-paste React Three Fiber code.
Provides tools for real-time inspection and modification of Three.js scenes, covering objects, materials, shaders, textures, animation, performance, and memory, with live preview and code generation capabilities.
Supports Three.js scenes rendered with WebGLRenderer, allowing real-time debugging and inspection of WebGL-based Three.js applications.
Supports Three.js scenes rendered with WebGPURenderer, allowing real-time debugging and inspection of WebGPU-based Three.js applications.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@threejs-devtools-mcpwhy is my model invisible? try it in red, then give me the code"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
threejs-devtools-mcp
MCP server for inspecting Three.js scenes in real time, trying changes live in the browser, and turning them into code. 69 tools cover objects, materials, shaders, textures, animation, performance and memory, plus website audits, video frame capture and Playwright helpers.
Zero changes to your project. Works with vanilla Three.js and React Three Fiber, on WebGLRenderer and WebGPURenderer.

Setup
1. Add the MCP server
claude mcp add threejs-devtools-mcp -- npx threejs-devtools-mcpAdd to claude_desktop_config.json:
{
"mcpServers": {
"threejs-devtools-mcp": {
"command": "npx",
"args": ["-y", "threejs-devtools-mcp"]
}
}
}Add to .cursor/mcp.json in your project:
{
"mcpServers": {
"threejs-devtools-mcp": {
"command": "npx",
"args": ["-y", "threejs-devtools-mcp"]
}
}
}Or use the HTTP transport — see Cursor setup guide.
Add to ~/.codeium/windsurf/mcp_config.json:
{
"mcpServers": {
"threejs-devtools-mcp": {
"command": "npx",
"args": ["-y", "threejs-devtools-mcp"]
}
}
}Add to .vscode/mcp.json:
{
"servers": {
"threejs-devtools-mcp": {
"command": "npx",
"args": ["-y", "threejs-devtools-mcp"]
}
}
}Add to opencode.json in your project:
{
"$schema": "https://opencode.ai/config.json",
"mcp": {
"threejs-devtools-mcp": {
"type": "local",
"command": ["npx", "-y", "threejs-devtools-mcp"],
"enabled": true
}
}
}2. Start your dev server and open the browser
Start your Three.js dev server as usual (npm run dev). The MCP server auto-detects the port from package.json and opens a browser at localhost:9222 with the devtools bridge injected.
Keep the browser tab open. The MCP server talks to your scene through a WebSocket bridge. Close the tab = tools stop working.
3. Ask the AI about your scene
"show me the scene tree"
"why is my model invisible?"
"try the car in red" ← live preview, nothing saved
"keep it" ← written into your code
"audit this site for mobile"
"record a 5-second clip at 60 fps"Related MCP server: threejs-devtools-mcp
Look now vs. change the code
Every tool is labelled, so you and the AI always know what touches your files:
Tools | Your code | |
Inspect |
| untouched |
Live preview |
| untouched; lost on page reload |
Debug visual | wireframe, bounding boxes, helpers, overlay | untouched; never needed in code |
For code |
| the AI writes this into your source |
Every live-preview change is recorded. pending_changes returns each one as before → after with ready-to-paste code (vanilla Three.js and React Three Fiber) and where to find it in your project. revert_changes undoes them in the browser.
For websites and videos
web_audit: checks for a blurry canvas (pixel ratio, missing resize), battery drain (rendering while idle or off-screen), heavy textures (oversized, not KTX2), expensive shadows, wrong color space and too many draw calls. Each finding comes with the fix.capture_frames: records a frame sequence for promo clips and reels. Time is virtualised, so the output is perfectly smooth at 30/60 fps even if your scene renders slowly. You get theffmpegcommand for MP4/WebM.
Skills
Ready-made workflows show up as slash commands in Claude Code, Cursor and other clients: inspect-scene, try-look, apply-to-code, web-perf-audit, prepare-video, debug-invisible, playwright-setup.
Playwright & Puppeteer
Three ways to connect, same tools in all of them: your own browser (default), a Chrome launched by the server (HEADLESS / CDP_PORT, shareable with Playwright MCP), or your own tests:
import { attachDevtools, waitForScene, threeCall } from 'threejs-devtools-mcp/playwright';
await attachDevtools(context, { connect: false });
await page.goto('http://localhost:5173');
await waitForScene(page);
expect((await threeCall(page, 'object_details', { name: 'Car' })).visible).toBe(true);See Browsers, Puppeteer & Playwright.
In-browser overlay
A built-in devtools panel with live performance stats, interactive scene graph, material editor, and 3D object preview. Activated automatically or via the toggle_overlay tool.

Tip: name your objects
Unnamed objects show as (unnamed) in the scene tree. Named objects are easier to find and modify:
// Three.js
mesh.name = "player";// React Three Fiber
<mesh name="player" geometry={geometry} material={material} />Documentation
Tools reference — all 69 tools by mode, skills, parameters
Browsers, Puppeteer & Playwright — connection modes, e2e tests, CI tips
Advanced setup — animations, scene export, configuration, transports
Cursor setup — step-by-step guide for Cursor
Token-efficient workflow — best practices for saving context
License
MIT
This server cannot be deployed
Maintenance
Related MCP Connectors
See the rendered web: design tokens, fonts, animation timings, WebGL shaders and 3D from any URL.
Hosted browser for AI agents: screenshots, post-JS DOM, console, WCAG. No install, no API key.
Live browser debugging for AI assistants — DOM, console, network via MCP.
Headless browser primitives for AI agents when sites need real JS rendering.
Related MCP Servers
- AlicenseNot gradedqualityAmaintenanceEnables AI agents to inspect and live-edit running Three.js or React Three Fiber scenes in the browser, covering objects, materials, shaders, textures, lights, animation, performance and memory without modifying the project. Previewed changes can be converted into ready-to-paste vanilla Three.js or React Three Fiber code, and it also supports website audits, video frame capture and Playwright helpers.965 npmMIT
- AlicenseNot gradedqualityAmaintenanceEnables AI agents to inspect, debug, and live-edit Three.js scenes — objects, materials, shaders, lights, animation, performance — in the browser, then convert those changes into ready-to-paste vanilla Three.js or React Three Fiber code without modifying the project. Also supports website audits, smooth video frame capture, and Playwright/Puppeteer integration.965 npmMIT
- AlicenseNot gradedqualityAmaintenanceEnables AI agents to inspect and edit live Three.js scenes — objects, materials, shaders, lighting, animation and performance — with zero project changes, previewing tweaks in the browser and converting them into ready-to-paste code. It also supports site performance audits, video frame capture, and Playwright/Puppeteer test integration.965 npmMIT
- AlicenseNot gradedqualityAmaintenanceEnables AI agents to inspect Three.js scenes in real time in the browser, preview material, shader, light, camera and animation changes live without touching project files, then convert the approved edits into ready-to-paste vanilla Three.js or React Three Fiber code. It also supports website performance audits, frame capture for video clips, and Playwright/Puppeteer test integration.965 npmMIT