Dolt

The SQL database you can branch, merge, diff, and clone — Git for your data, MySQL-compatible and ready for multi-agent AI workflows.

23.8Kstars
822forks
Apache License 2.0
Go

Dolt is a fully version-controlled SQL database that brings Git semantics to your data. Every table, row, and schema change is tracked as a commit, enabling you to branch, merge, diff, cherry-pick, revert, and clone your database exactly the way you manage source code. Connect to it with any MySQL-compatible client and start querying immediately — no migration from existing tooling required.

Under the hood, Dolt exposes version control as first-class SQL: system tables, functions, and stored procedures let you query diffs between branches, inspect commit history, identify who changed which row and when, and resolve merge conflicts all within standard SQL. The command-line interface mirrors Git so closely that developers already know how to use it before reading a single doc page.

Dolt is built by DoltHub and pairs with a hosted sharing platform (DoltHub), a self-hostable hub (DoltLab), and a fully managed cloud service (Hosted Dolt). The ecosystem makes collaborative data workflows as natural as collaborative code workflows — open a pull request for a data change, have a teammate review it, and merge when it looks right.

With AI agent memory emerging as a top use case, Dolt provides a uniquely durable, auditable store for multi-agent systems that need to checkpoint state, roll back bad decisions, and trace exactly what an agent changed and when. Its MySQL compatibility means any agent framework that already speaks SQL can adopt Dolt with zero driver changes.

What You Get

  • MySQL-compatible SQL server — connect any MySQL client, ORM, or framework without changing a line of application code
  • Full Git command set for datadolt branch, dolt commit, dolt merge, dolt diff, dolt clone, and dolt push work exactly like their Git counterparts
  • SQL-accessible version control — query dolt_log, dolt_diff_<table>, dolt_commit_diff_<table>, and dolt_conflicts tables directly from any SQL client
  • DoltHub sharing platform — publish and discover datasets on a GitHub-style hub, collaborate via pull requests, and fork public databases
  • DoltLab self-hosted hub — run your own DoltHub instance on-premises for private dataset collaboration
  • Hosted Dolt managed service — fully managed Dolt servers with backups, monitoring, and high availability without operating your own infrastructure
  • Branch-based development workflows — develop schema and data changes on feature branches, review them in CI, and merge when approved
  • Doltgres PostgreSQL-compatible sibling — the same version-control model for teams that prefer the Postgres wire protocol

Common Use Cases

  • Data auditing and compliance — every row change is permanently recorded with author, timestamp, and commit message, producing an immutable audit trail for regulated industries
  • AI agent memory — give LLM agents a durable, branchable memory store so multi-agent and multi-machine workflows can checkpoint progress, roll back mistakes, and audit decision history
  • Dataset collaboration — teams working on training data, reference datasets, or curated data products can open pull requests, review changes row-by-row, and merge with conflict detection
  • Schema migration safety — test DDL changes on a branch, validate the diff, and merge to main only when the migration is confirmed correct — no irreversible production surprises
  • Environment parity — clone production data to a development or staging branch, sanitize it, and give every developer a reproducible snapshot without copying large SQL dumps
  • Data pipeline reproducibility — tag dataset versions used in each model training run and reliably reproduce any past experiment by checking out the exact data commit

Under The Hood

Dolt is built on a custom content-addressed storage engine called Noms Binary Serialization (NBS), which organizes all data in immutable, hash-linked chunks similar to Git objects. Table data is stored in Prolly Trees — a probabilistic B-tree variant that produces stable, deterministic chunk boundaries when data changes, making structural diffs efficient and merge operations incremental rather than full-table rewrites. This design ensures that two databases with identical data always produce identical root hashes, enabling cryptographic verification of database state.

The SQL layer is powered by a heavily customized fork of Vitess (dolthub/vitess) combined with go-mysql-server, giving Dolt a full MySQL-compatible parser, planner, and execution engine. Version control operations — branching, merging, cherry-picking, conflict resolution — are all surfaced as SQL procedures and system tables, so the entire version control model is queryable through standard SQL without any Dolt-specific client library.

Code quality is high: the Go codebase is well-organized into distinct packages (storage engine, SQL engine, CLI, server, replication), carries a comprehensive test suite including a full SQL logic test runner, and ships releases at a cadence of roughly one per week. The project uses a custom Flatbuffers-based serialization format (go/serial) for its on-disk structures, enabling zero-copy deserialization at read time.

What makes Dolt architecturally unique is its three-way merge capability for tabular data: rather than treating a table as a blob, Dolt merges at the row level, detecting conflicts only when two branches modify the same primary-key row in incompatible ways. This makes data merges far less painful than naive file-level diffs and is the foundational capability that separates Dolt from every other version control solution applied to databases.

Self-Hosting

DoltHub offers Hosted Dolt, a fully managed cloud service running production Dolt servers with automated backups, high availability, monitoring, and dedicated support. DoltLab is a self-hostable version of DoltHub for organizations that need private dataset collaboration behind their own firewall. Enterprise customers working with sensitive data or requiring custom SLAs can contact DoltHub directly. The Apache-2.0 license allows unrestricted commercial use with no seat limits.

Join founders buildingwith open source

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

Subscribe on Substack

No spam. Unsubscribe anytime.

Join 750+ subscribers
No spam. Unsubscribe anytime.

Search