# Dolt
Dolt is a SQL database with [[Git]]-style versioning baked into the storage engine. Branch, diff, merge, log, and pull requests work on tables instead of files. Created by DoltHub (the company also runs a hosted hub for shared databases), Dolt is wire-compatible with MySQL; existing clients connect without modification, but every commit produces a content-addressable, replayable history.
## What Makes It Different
Most databases treat history as an afterthought (audit logs, change-data-capture, temporal tables bolted on). Dolt inverts the model: every state of every table is a content-addressed commit. The query engine reads the working set; everything else (branches, tags, diffs, merges) operates on the commit graph beneath. The result is a database where time travel, blame, and merge are first-class operations rather than tooling glued on top.
## Core Operations (the Git verbs, on tables)
- `dolt init` / `dolt clone`: create or copy a versioned database
- `dolt branch` / `dolt checkout`: work on parallel timelines of the same data
- `dolt diff`: row-level diff between any two commits or branches
- `dolt merge`: three-way merge of table contents with conflict resolution
- `dolt log` / `dolt blame`: full history of who changed which row, when, and why
- `dolt push` / `dolt pull`: sync with remote databases, including DoltHub
- `AS OF` SQL: query any past state of any table from a normal SELECT
## Why It Matters
Three problems Dolt solves cleanly that most stacks bolt together with duct tape:
1. **Reproducible analytics**: pin a query to a specific commit; the result is deterministic forever
2. **Collaborative datasets**: branch, edit, and PR a shared database the same way teams do code
3. **Auditability**: every row change is signed, dated, and replayable; compliance "for free"
This is the durability and observability story that frames it as a foundational layer for systems like [[Gas City]], where every action of every agent must be replayable.
## Trade-offs
- **Storage overhead**: keeping every version of every row costs space (mitigated by content-addressed deduplication, but real)
- **Write throughput**: not in the same league as a tuned MySQL on point updates; the commit graph adds bookkeeping
- **Maturity**: production-ready for moderate workloads, not yet a drop-in replacement for high-throughput OLTP at scale
## Where It Fits
- Versioned reference data (mappings, codelists, configuration, ML feature stores)
- Public datasets with collaborative editing (DoltHub hosts many)
- Audit-critical systems where "who changed what and when" must be replayable
- Agent infrastructure (see [[Gas City]]); making every agent action a commit on a queryable timeline
## References
- Official site: https://www.dolthub.com/
- GitHub: https://github.com/dolthub/dolt
- Documentation: https://docs.dolthub.com/
## Related
- [[Git]]
- [[Database]]
- [[Database Management Systems (DBMS)]]
- [[Relational Databases (RDBMS)]]
- [[SQL]]
- [[Gas City]]