Skip to main content
Multilingual TursoDB, MVCC & AI Agent database guides Read Engine Guide →
TursoDB.cn · SQLite in Rust

Millions of Databases.
One Architecture.

Built on SQLite and rewritten in Rust. Lightweight enough to run locally or in the cloud, giving every user, AI agent, and tenant an isolated database.

agent-db.ts 142ms
const db = await turso.databases.create({
  name: `agent-${id}`,
  group: 'fra-edge',
});
// Isolated SQLite file + scoped token
Used by engineering teams building multi-tenant apps and AI agents
Superhuman
Mastra
Val Town
Resonate
Drizzle
CTO
Poke
Spice AI

Traditional databases weren't built for a world where every agent needs its own.

For decades, the default pattern has been one shared database per application, scaled inside a single instance. That model hits clear limits when AI agents need isolated workspaces, consumer apps need per-user privacy, multi-tenant platforms need hard customer boundaries, and global teams need regional data residency.

Turso is designed from the ground up to manage millions of small databases rather than one large shared instance.

Interactive Isolation Lab

Centralized Model

One shared database

WAL Lock: Idle · Shared queue
TursoDB

A fleet of isolated databases

Fleet Control Plane 2,418,904 DBs

Database per tenant

0 lock waits · Per-entity boundary active

Provision an isolated database per entity in under a minute.

SQLite-compatible with native SDKs for TypeScript, Python, Rust, and Go—from local files to managed cloud groups.

import { createClient } from '@tursodatabase/api';

const turso = createClient({
  org: process.env.TURSO_ORG,
  token: process.env.TURSO_PLATFORM_TOKEN,
});

// Every AI agent gets its own isolated workspace
const agentDb = await turso.databases.create(`agent-${agentId}`, {
  group: 'agents-eu',
  seed: { type: 'database', name: 'agent-template' },
});

const token = await turso.databases.createToken(agentDb.name, {
  expiration: '1h',
});
1 DB per agent session · Scoped 1h JWT TypeScript

Replicate to the device. Sync to the cloud. One database everywhere.

Embedded replication lets the same Turso database run on a user's device and stay synchronized with the cloud. Reads and writes hit local storage first, then sync deltas once the device is online, so offline apps and AI agents do not need a second data layer.

How embedded replication works
“We chose Turso because embedded replication and sync simply aren't available anywhere else.”

Simon Henriksen

CTO, Kin

Simon Henriksen

One pattern across real production workloads.

Engine Labs

Tens of thousands of AI agent teams, each coordinating through its own database on a $500/month plan.

Engine Labs' CTO.new gives every agent team its own Turso database as a coordination layer, keeping agent state separate from core application tables.

Read Per-Agent Architecture
Adaptive

Over 2 million databases created—one for every prompt and every revision of each user-built app.

Adaptive allocates a separate Turso database for each generated app revision, supporting fast branching and clean rollbacks without mixing app data.

Read Rust Engine Evolution
Poke

A complete website from a single text message, each shipping with its own live database.

Every user project starts with a dedicated SQLite database through a single API call rather than manual database provisioning.

Read Local-First Sync Guide

Built for enterprise security and compliance.

Per-database encryption with customer-held keys, Bring-Your-Own-Cloud deployment on AWS, SOC 2 Type II controls, and regional data residency for GDPR and HIPAA requirements—with predictable cost curves as tenant counts grow.

BYOC deployment on AWS
Per-database encryption
SOC 2 Type II, GDPR, HIPAA-ready

Start locally. Scale to cloud groups when needed.

Open-source Turso

SQLite-compatible and MIT-licensed. Runs directly on your laptop, servers, and user devices using the same engine and SQL interface you ship to production.

Install locally

Turso Cloud

Managed provisioning, global replication, observability, BYOC, and per-database encryption—ready from signup to production in minutes.

Try Cloud free

Five properties built into the architecture, not bolted on afterward.

01

A database per agent, user, or tenant

Create thousands or millions of isolated databases via API, each with its own storage file and access token.

Read per-agent isolation guide
02

File-sized footprint, cloud scale

Compatible with SQLite and rewritten in Rust for async I/O, so the same engine runs on laptops, containers, and edge regions.

Explore Rust Engine & MVCC
03

Costs that track real usage

Idle databases consume no active compute—only compressed storage bytes—avoiding per-instance minimum charges.

View Turso Cloud pricing
04

Isolated by default

Physical file separation, customer-held encryption keys, and regional pinning keep tenant queries strictly separated.

Read architecture FAQ
05

One engine from local to cloud

Run the same SQLite-compatible engine on user devices and servers, connected through frame-level Turso Sync.

Explore Turso Sync

Start with a single file. Scale to millions of databases.

Use the same SQLite-compatible engine from your first local prototype to multi-tenant production workloads.

Independent developer community at tursodb.cn · Official turso.tech free tier includes 100 databases, 500M row reads, and 10M row writes/mo.

Search
Press Esc to close · Powered by Pagefind