SpacetimeDB
A relational database that also runs your application logic and syncs state to connected clients in real time.
At a Glance
About SpacetimeDB
SpacetimeDB, also branded Spacetime and designed and engineered by Clockwork Labs, is a relational database that doubles as a server. Developers upload application logic as a module into the database, and clients connect to it directly with no separate server in between. The latest GitHub release listed is v2.14.1.
What It Is
SpacetimeDB is a reactive backend platform that combines a relational database, server logic, auth, deployment and real-time sync. Modules define tables (data) and reducers (logic) and can be written in Rust, C#, TypeScript or C++. Each reducer runs as an ACID transaction. Clients call reducers and subscribe to tables, and committed changes are pushed to subscribed clients automatically, without polling or a separate pub/sub layer.
Workflow and Setup
Developers install the spacetime CLI, log in with GitHub or Google, and can start from a template with spacetime dev --template chat-react-ts. That command creates a project, publishes it to Maincloud, and rebuilds and republishes on file changes. A local Standalone server can be run with spacetime start, or via Docker. Quickstarts cover React, Next.js, Vue, Nuxt, Svelte, Angular, TanStack Start, Remix, browser, Bun, Deno, Node.js, TypeScript, Rust, C#, and C++. The docs also include a prompt that lets coding agents such as Claude Code, Codex or Cursor set themselves up to build with it.
Durability and Client SDKs
Every data-changing transaction is written to an on-disk commitlog that is replayed for crash recovery. Since 2.0, clients get confirmed reads by default, so subscription updates and reducer results are held until the transaction is durable; apps can opt out for lower latency. Client SDKs exist for TypeScript, Rust, C# (including Unity), and C++ (Unreal Engine).
Where It Fits
The README positions it for web app backends such as collaborative tools, dashboards and chat, as well as multiplayer games, and says it is optimized for low-latency transactional workloads rather than batch or analytical queries. The README states that the backend of the MMORPG BitCraft Online runs as a single SpacetimeDB module. The source is licensed under the Business Source License 1.1.
Community Discussions
Be the first to start a conversation about SpacetimeDB
Share your experience with SpacetimeDB, ask questions, or help others learn from your insights.
Pricing
Maincloud Free
Permanent free tier on Maincloud with 2,500 TeV free credit per month.
- 2,500 TeV free credit / month
- ~3,000,000 function calls
- ~12.5 GB egress bandwidth
- ~1 GB table storage
- Unlimited monthly active users
Maincloud Pro
Pro tier with 100,000 TeV free credit per month and pay-as-you-go beyond.
- 100,000 TeV free credit / month
- then 2,592 TeV / $ thereafter
- ~120,000,000 function calls
- ~500 GB egress bandwidth
- ~40 GB table storage
- Early access to Beta features
- Automatic replication & backups
- Up to 1 month of metrics history
- 10 collaborators per database
- 10 users included, then $25 / user
- Email support
- SLA / uptime guarantee
Maincloud Team
Organization tier with 250,000 TeV free credit per month and pay-as-you-go beyond.
- 250,000 TeV free credit / month
- then 2,592 TeV / $ thereafter
- ~300,000,000 function calls
- ~1,250 GB egress bandwidth
- ~100 GB table storage
- Named organization
- Ability to reserve dedicated nodes
- Unlimited collaborators per database
- 10 users per organization, then $25 / user
- Organization-wide permissions
- Read-only access to dashboards
- Priority email support & SLAs
Enterprise
Custom pricing with on-prem and BYO cloud options.
- Custom on-prem & cloud deployment options (BYO Cloud)
- Custom scalability & replication
- Customized pricing & licensing
- Enterprise SLA & uptime
- 24x7x365 enterprise support
- Dedicated onboarding engineer
Capabilities
Key Features
- Relational database with ACID transactions
- Server logic as modules in Rust, C#, TypeScript or C++
- Reducers, procedures and views
- Real-time subscriptions that sync data to clients
- Type-safe API generated from schema
- Built-in auth and role-based access control
- Persistent commitlog with confirmed reads
- Cloud deployment via Maincloud and local Standalone mode
- Project templates such as team chat, collaborative board and multiplayer games
- Coding agent setup guide, skills and MCP server
