playcanvas / engine
Powerful web graphics runtime built on WebGL, WebGPU, WebXR and glTF
description README.md
PlayCanvas Engine


User Manual · API Reference · Examples · Blog · Forum
PlayCanvas is an open-source web graphics engine built on WebGPU and WebGL2. Use it to create interactive 2D and 3D apps, games and visualizations that run in any browser on any device.
Install
npm install playcanvas
Or scaffold a full project in seconds with create-playcanvas:
npm create playcanvas@latest
Release notes for every version are on the Releases page.
Usage
Here's a super-simple Hello World example - a spinning cube!
import * as pc from 'playcanvas';
const canvas = document.createElement('canvas');
document.body.appendChild(canvas);
// create a graphics device, preferring WebGPU and falling back to WebGL2
const device = await pc.createGraphicsDevice(canvas, {
deviceTypes: [pc.DEVICETYPE_WEBGPU]
});
// create an app with only the component systems it uses
const options = new pc.AppOptions();
options.graphicsDevice = device;
options.componentSystems = [
pc.RenderComponentSystem,
pc.CameraComponentSystem,
pc.LightComponentSystem
];
const app = new pc.AppBase(canvas);
app.init(options);
// fill the window and keep the canvas sized to it
app.setCanvasFillMode(pc.FILLMODE_FILL_WINDOW);
app.setCanvasResolution(pc.RESOLUTION_AUTO);
window.addEventListener('resize', () => app.resizeCanvas());
// create a box, a camera and a light
const box = new pc.Entity('cube');
box.addComponent('render', { type: 'box' });
app.root.addChild(box);
const camera = new pc.Entity('camera');
camera.addComponent('camera', { clearColor: new pc.Color(0.1, 0.2, 0.3) });
camera.setPosition(0, 0, 3);
app.root.addChild(camera);
const light = new pc.Entity('light');
light.addComponent('light');
light.setEulerAngles(45, 0, 0);
app.root.addChild(light);
// spin the box and start the app
app.on('update', dt => box.rotate(10 * dt, 20 * dt, 30 * dt));
app.start();
Want to play with the code yourself? Edit it on CodePen.
The package includes TypeScript declarations, and it also runs without a build step using an import map and a CDN build. Using the Engine Standalone walks through both setups, and Bundle Size and Tree Shaking lists the component systems and resource handlers an app can register.
Features
- 🧊 Graphics - Advanced 2D + 3D graphics engine built on WebGL2 & WebGPU, with physically based materials, clustered lighting, soft shadows and WebGPU compute shaders
- 💠 Gaussian Splatting - First-class support for loading, streaming and rendering 3D Gaussian Splats
- 🎨 Post-Processing - HDR effects pipeline with bloom, SSAO, TAA, depth of field and color grading
- ✨ Particles - GPU-accelerated particle systems
- 🔘 User Interface - Text, images, buttons, layouts and scroll views for 2D and 3D UI
- 🥽 XR - Built-in support for immersive AR and VR experiences via WebXR
- ⚛️ Physics - Full integration with 3D rigid-body physics engine ammo.js
- 🏃 Animation - Powerful state-based animations for characters and arbitrary scene properties
- 🎮 Input - Mouse, keyboard, touch and gamepad APIs
- 🔊 Sound - 3D positional sounds built on the Web Audio API
- 📦 Assets - Asynchronous streaming system built on glTF 2.0, Draco, Meshopt and Basis compression
- 📜 Scripts - Write game behaviors in TypeScript or JavaScript
Developing with AI
Coding agents: start from the Engine guides index and the Engine API index, which link a Markdown version of every page. Developing with AI explains how to set up an agent on a project, and PlayCanvas Skills add task-specific workflows to compatible agents.
Ecosystem
Build with PlayCanvas your way:
| Package | Description |
|---|---|
playcanvas | Core engine (you are here) |
@playcanvas/react | React renderer for PlayCanvas |
@playcanvas/web-components | Declarative 3D via Custom Elements |
create-playcanvas | Project scaffolding CLI |
| PlayCanvas Editor | Browser-based visual editor |
Project Showcase
Many games and apps have been published using the PlayCanvas engine. Here is a small selection:
More in Uncategorized

openclaw / openclaw
OpenClaw is an open-source personal AI assistant that runs on your own devices and connects to the communication platforms you already use. It provides a fast, always-available assistant that can respond, listen, speak, and perform tasks across desktop and mobile devices.

mattpocock / skills
Created by renowned TypeScript educator Matt Pocock, Skills is a collection of practical, reusable workflows for AI coding agents such as Claude Code and Codex. The skills help developers plan, test, debug, and build real-world software while keeping control of the engineering process

obra / superpowers
An agentic skills framework & software development methodology that works.

affaan-m / everything-claude-code
The agent harness performance optimization system. Skills, instincts, memory, security, and research-first development for Claude Code, Codex, Opencode, Cursor and beyond.








](ht