The
Monster
Database Engine.

- 28
- 2
- 1.8M+
- 25K+
26 of them published on crates.io
The VFS (mmap, shared memory) and the optional C ABI shim
Under crates/, tests included
v0.4.9 release gate; the 68 failures are listed in the changelog
What Makes It Different
Some of this works today and some of it is still on the bench. Each card says which. Hover a badge for what it means.
Concurrent Writers
BEGIN is promoted to BEGIN CONCURRENT by default.Serializable by Default
Your Existing SQLite Files
.db files with rollback journal or , in UTF-8 or UTF-16. Files it writes stay readable by stock sqlite3.Safe Rust Core
unsafe by default. Two crates opt out: the VFS, which needs raw pointers for mmap and shared memory, and the optional C ABI shim. The parser, planner, VDBE, B-tree, pager and MVCC code are all safe Rust.SQLite's SQL, Checked Against SQLite
Built-in Extensions
generate_series are registered out of the box. FTS3/FTS4 virtual tables, dbstat and carray are not there yet.Transaction Telemetry
Async, With Real Cancellation
Time-Travel Queries
SELECT ... FOR SYSTEM_TIME AS OF COMMITSEQ 42 reads the table as it was after commit 42. Today this works on :memory: databases only; file-backed history is designed but not built.RaptorQ WAL Repair
-wal-fec sidecar. Opening a damaged database doesn't use them automatically yet; there is an explicit repair API on Unix.Same-Page Merging
SQLITE_BUSY_SNAPSHOT and retries.Page-Level Encryption
PRAGMA key is silently ignored and your data is written unencrypted.Where It Stands
Works today
On by default in the current compatibility runtime.
- Multiple writers in one processOne Connection per thread against the same file. Writers on different pages overlap; same-page conflicts retry with SQLITE_BUSY_SNAPSHOT.
- Serializable isolationPage-level SSI is on by default. PRAGMA fsqlite.serializable = OFF drops to snapshot isolation.
- Standard SQLite filesRollback journal and WAL, UTF-8 and UTF-16. Stock sqlite3 can read what FrankenSQLite writes.
- ExtensionsFTS5, JSON1 (json_each, json_tree), R-tree and geopoly, ICU, generate_series.
- Observability PRAGMAsfsqlite_txn_stats, fsqlite_transactions, fsqlite_txn_advisor, fsqlite_txn_timeline_json.
- CLI and packagesSigned prebuilt binaries for Linux (x86-64, ARM64), macOS and Windows, plus the fsqlite crates on crates.io.
Partly there
Opt-in, or usable in some configurations with known edges.
- Multi-process writersShared-memory coordination exists, but MVCC authority is still process-local. Proven only up to the scale the swarm harness has run.
- Interop with stock SQLiteEither engine can open the other's files. Running both on the same file at the same time is not supported.
- Time travelFOR SYSTEM_TIME AS OF works on :memory: databases. File-backed history is design work.
- WAL repair symbolsGenerated in the background into a -wal-fec sidecar (PRAGMA raptorq_repair_symbols sets how many). Normal recovery doesn't use them; an explicit repair_and_open API exists on Unix.
- Compiled executionMost table work compiles to VDBE bytecode. Some CTE, view, join and window shapes still use a compatibility executor.
- VDBE JITFunctional but off by default. PRAGMA fsqlite.jit_enable = 1 opts in.
- Browser buildA WASM build with a TypeScript SDK and worker. In-memory, with explicit IndexedDB snapshots; the packages aren't on npm yet.
Built, not wired
Code and tests exist; the default runtime doesn't call them.
- Safe write-merge ladderIntent replay and structured page patches. Tracked as bd-3d5y3 / bd-p4dcv.
- Page encryptionXChaCha20-Poly1305 with Argon2id key wrapping lives in fsqlite-pager. No PRAGMA key/rekey dispatch yet.
- Research codeLearned indexes, database cracking, a cooling-stage cache protocol and pointer swizzling in fsqlite-btree, plus an ARC cache policy and BOCPD workload detection. Implemented and tested; the runtime doesn't call them.
- Vectorized operatorsBatch hash join, sort and aggregation kernels are benchmarked but have no live call sites. Only the vectorized MakeRecord encoder is on.
On the drawing board
Specified in detail, implemented in pieces.
- Native mode (ECS)An append-only, RaptorQ-encoded commit stream as the source of truth. The WAL pieces are landing on main now.
- File-backed time travelA .fsqlite-history sidecar is the chosen design; not implemented.
- Cross-process MVCCMapped page-lock tables and MVCC shared memory exist as infrastructure only.
WAL_WRITE_LOCK) decides who that is, and everyone else waits or gets SQLITE_BUSY. Add cores and the write path doesn't get any wider. Most apps end up funneling every write through one thread.FrankenSQLite replaces that lock with . Each writer works against its own and records new versions of the pages it changes. Writers on different pages do their work in parallel; commit still has a short coordinated step to publish the result. If two writers change the same page, the second one to commit gets
SQLITE_BUSY_SNAPSHOT and retries. The race below is a simplified picture of the difference.The visibility rule is one comparison: a page version committed after your snapshot is invisible to you. Click through the tree below to watch produce new page versions while the old tree stays intact for readers that are still using it.
sqlite3 can open its files. A lookup walks from the root page to a leaf, binary-searching the cells on each page.Pages are also the unit of versioning. A write produces a new version of the leaf it touches, plus any pages a split or merge changes, and decides which transactions can see which version. Step through below to watch the read path descend and the write path fork.
At commit, it checks two things. First, : if a page you wrote changed since your snapshot, you lose and retry. Second, : it tracks between concurrent transactions and aborts any transaction that would become the pivot of a dangerous structure (the , applied per page). PostgreSQL uses the same idea at row granularity. If you can live with write skew,
PRAGMA fsqlite.serializable = OFF turns the second check off. The two visualizations below show the dependency graph and a commit sequence being validated.FrankenSQLite keeps SQLite's WAL format and its , so a database can move between it and stock SQLite after a checkpoint. (Running both engines on the same file at the same time is not supported.) With concurrent writers, the interesting part is the commit itself: each connection validates and publishes its frames inside a short guarded section, so the log stays one ordered sequence even though the work that produced it ran in parallel. Use the tabs below to switch between normal appends, a checkpoint, and crash recovery.
fsqlite_txn_stats gives lifecycle counters, fsqlite_transactions lists the active ones with their age and read/write activity, and fsqlite_txn_advisor flags long transactions, large read sets, deep savepoint stacks and rollback pressure against thresholds you can tune. fsqlite_txn_timeline_json returns the same picture as . The tabs below show what a healthy and an unhealthy timeline look like.FrankenSQLite sets
unsafe_code = "forbid" for the whole workspace. Two crates override it locally: fsqlite-vfs, because mmap and shared-memory regions need raw pointers, and the optional fsqlite-c-api, because FFI does. The parser, planner, VDBE, B-tree, pager, WAL and MVCC code are safe Rust, so those classes of bug can't appear there. for PageNumber, TxnId, PageSize and friends turn mixed-up integers into compile errors. Switch to the Rust tab in the newtype demo to see the compiler catch a mistake C would accept.OpenRead, Rewind, Column and ResultRow, run by a register-based virtual machine against the layer. FrankenSQLite has 190+ opcodes.Most table work takes this compiled path today. Some shapes (certain CTEs, views, joins and window queries) still run through an interpreted compatibility executor while their lowering is finished. Step through the program below to watch the program counter advance and rows come out of the opcodes.
Connection, prepare, execute, rows of SqliteValue. The one thing that will look unusual is that every call is async: the engine runs on asupersync, so you build a runtime and .await each operation. A Connection stays on the thread that opened it; for concurrent writers, open one per thread. Getting started has the multi-writer version.01#![recursion_limit = "512"] // the engine's futures nest deeply02 03 asupersync::runtime::RuntimeBuilder;04 fsqlite::{Connection, SqliteValue};05 06 main() -> Result<(), Box<dyn std::error::Error>> {07 // A small blocking pool for file I/O, the same setup the fsqlite CLI uses.08 runtime = RuntimeBuilder::current_thread().blocking_threads(1, 2).build()?;09 runtime.block_on( {10 conn = Connection::open("app.db").?;11 12 conn.execute(13 "CREATE TABLE IF NOT EXISTS users (14 id INTEGER PRIMARY KEY,15 name TEXT NOT NULL,16 email TEXT UNIQUE17 );",18 )19 .?;20 21 conn.execute_with_params(22 "INSERT INTO users (name, email) VALUES (?1, ?2);",23 &[SqliteValue::from("Alice"), SqliteValue::from("alice@example.com")],24 )25 .?;26 27 // Prepared statements borrow the connection; drop them before close().28 {29 stmt = conn.prepare("SELECT id, name FROM users WHERE name = ?1;").?;30 row stmt.query_with_params(&[SqliteValue::from("Alice")]).? {31 println!("{:?} {:?}", row.get(0), row.get(1));32 }33 }34 35 conn.close().36 })?;37 Ok(())38}Designed, Built, Not Yet Switched On
Everything above runs in the default engine today. The next four sections are the ideas FrankenSQLite is best known for, and none of them is fully live yet. Some have working, tested code that the commit path doesn't call; some work only in part; one is a design with pieces landing on main every week. Each section says exactly where it stands, so you can tell the plan from the product.
The plan is to store next to the WAL. A fountain code turns K source symbols into as many extra symbols as you like, and almost any K of them (plus a couple) are enough to rebuild the original. Corrupted frames can then be reconstructed during recovery instead of discarded. The demo below shows the idea on a handful of pages; the overhead and failure counts in it are illustrative.
StatusFile-backed connections running with a blocking thread pool generate repair symbols for durable WAL ranges into a -wal-fec sidecar, in the background (PRAGMA raptorq_repair_symbols sets how many). Ordinary recovery still stops at the first bad checksum and doesn't consult them; an explicit repair_and_open API on Unix can.
.db file can still be produced from the stream for compatibility.The code is : the original bytes are stored as-is and the sit alongside them, so ordinary reads don't decode anything. Press Start DB Writers below for a simplified picture of data and repair symbols streaming to disk.
StatusNative mode is under construction. Commit capsules, RaptorQ-encoded WAL objects and native page groups are landing on main, but there is no stable switch for it on Connection. Everything you run today uses standard SQLite files.
SQLITE_BUSY_SNAPSHOT and retries.The is the planned fix. Each writer keeps a log of what it meant to do at the B-tree level (“insert rowid 42”, “delete this index entry”). On a same-page conflict, the engine first tries to against the winner's version of the page. If that doesn't apply, it tries a structured patch that merges changes cell by cell. Raw byte-level XOR merging is deliberately ruled out, because two byte-disjoint edits can still produce an invalid page. Only a conflict that survives both rungs aborts. The demo below walks through a merge step by step.
StatusThe rebase and patch-merge code lives in fsqlite-mvcc and is exercised by tests, but the live commit path doesn't call it and the intent log isn't populated during writes. Today every same-page conflict is resolved by abort and retry.
Keys use an : a random data key encrypts the pages, and a key derived from your passphrase with encrypts the data key. Changing the passphrase re-wraps one 32-byte key instead of rewriting the file. Random nonces avoid any global counter, so VM snapshot rollbacks and crashes can't cause nonce reuse. Step through the pipeline below to follow a page through it.
StatusNot usable yet. The implementation is in fsqlite-pager, but no PRAGMA key or rekey reaches it. Because unknown PRAGMAs are ignored (as in SQLite), PRAGMA key = '...' succeeds and the database is still written in plain text.
Turso is ahead as a product, with bindings, sync and a mature simulation-testing setup. C SQLite has 25 years of production use that nothing here can match. DuckDB solves a different problem (analytics, columnar storage). The table describes FrankenSQLite as it runs today, gaps included.
| Feature | C SQLite | Turso | libSQL | DuckDB | |
|---|---|---|---|---|---|
| Implementation language | Rust | C | Rust | C (SQLite fork) | C++ |
| Concurrent writers | Default (plain BEGIN) | One at a time | BEGIN CONCURRENT in MVCC mode | One at a time | Yes |
| Version granularity | Page | None (one writer) | Row | None (one writer) | Row |
| Isolation with concurrent writers Snapshot isolation allows write skew; serializable does not. | Serializable (page SSI) | Serializable by serializing | Snapshot isolation | Serializable by serializing | Snapshot isolation |
| Opens existing SQLite files | Yes | Yes | Yes; MVCC mode adds its own log | Yes | Via extension |
| Memory safety | Safe Rust; unsafe in 2 crates | Manual | Rust with unsafe in core | Manual | Manual |
| Corruption repair | WAL repair symbols; auto-recovery pending | Detect only | Detect, truncate torn tail | Detect only | Detect only |
| Encryption at rest | Implemented, not wired | Paid SEE extension | Experimental | Yes | Yes |
| Async API | Yes (asupersync) | No | Yes | Client libraries | No |
| Analytical workloads | Row store | Row store | Row store | Row store | Columnar, vectorized |
| Track record | Pre-1.0, since Feb 2026 | 25 years | Beta | Production | Production |
fsqlite, which pulls in the rest.Public API: Connection::open, execute, query, prepare
Connection hub: statement dispatch, transactions, schema, VDBE bridge
PageNumber, PageSize, TxnId, SqliteValue, opcodes, serial types
Error variants, SQLite error-code mapping, transient-error detection
OS abstraction: files, locks, mmap and shared memory
Page cache (S3-FIFO eviction), rollback journal, write-back
frames, checkpoints, WAL index, crash recovery
Page-level , snapshots, SSI validation, version GC
B-tree cells, page splits, overflow chains, cursors
Typed AST for statements and expressions
Hand-written lexer and parser, Pratt expressions
Name resolution, WHERE analysis, join ordering, index choice
bytecode VM with 190+ opcodes and code generation
Scalar, aggregate, window, date/time and math functions
FTS5 full-text search with BM25 ranking
FTS3/FTS4 query helpers (no virtual-table module yet)
JSON1 functions plus json_each and json_tree
R-tree spatial indexes and geopoly functions
Changesets and patchsets (manual library API)
ICU collation and Unicode case folding
generate_series plus uuid and decimal helpers
Metrics, tracing, latency and conflict telemetry
The fsqlite shell: REPL, -c, .read, .dump, output modes
Optional SQLite-style C ABI shim
Experimental WebAssembly build behind the TypeScript SDK
Conformance and differential testing against C SQLite
Workload replay, swarm tests and the benchmark matrix
Health checks for Beads issue databases
Spec first
Measure the whole workload
Write down what didn't work
Dogfood it early
What about speed?
There is no current performance number to quote. The May 2026 benchmark matrix looked very good: FrankenSQLite was ahead of C SQLite on 79 of 93 scenarios, with the biggest wins on multi-writer workloads, and behind on small single-threaded write loops, where every row paid MVCC bookkeeping that C SQLite skips. In July the project declared those results non-citable. The storage stack had moved to async I/O, and some of the older runs lacked provenance or compared asymmetric settings. Until a clean, reproducible matrix exists for the current code, the README makes no numeric claims, and neither does this site.
An 18,000-line spec, then the first engine
The project starts on February 6. The design spec grows to 18,231 lines over dozens of revision passes before any serious code is written.
The spec is broken into hundreds of Beads issues, and a swarm of coding agents works through them.
About 2,500 commits land in the first six weeks. MCP Agent Mail's Rust rewrite starts using FrankenSQLite almost immediately.
The performance campaign
A benchmark matrix pits FrankenSQLite against C SQLite across reads, inserts, updates and deletes, from 1,000 to 100,000 rows, on 1 to 32 threads.
Every optimization that failed to move the matrix goes into a negative-results ledger, which agents read before trying the next idea. It now holds 648 entries.
The May 9 run had FrankenSQLite ahead on 79 of 93 scenarios. Those numbers predate the async storage rewrite and are no longer treated as release evidence.
Releases, dogfooding, and going async
Regular releases begin, with signed prebuilt binaries and checksum-verifying installers.
cass, beads_rust and the Rust MCP Agent Mail build on FrankenSQLite, and their bug reports drive much of the fix list.
In late July the storage stack moves to async I/O (released as v0.2.0 on August 4), and the project withdraws its performance numbers until they can be re-measured cleanly.
One version for every crate
v0.4.0 aligns with asupersync 0.5. From v0.4.4 on, every crate ships at the same version.
Groundwork for cross-process MVCC lands: a mapped page-lock table and MVCC shared memory, not yet in charge of the public Connection.
A TypeScript SDK and WASM worker land in the repo, along with UTF-16 database support and a long list of stock-SQLite parity fixes.
v0.4.9 and native storage
v0.4.9 ships on October 3. Its release gate records 25,211 passing test results and 68 failures, each one reviewed and listed in the changelog.
On main, native-mode WAL work is landing: page groups published through shared durability barriers and sealed transaction handles, plus a feature-gated service that batches native commits so writers share fsyncs. None of it is switched on for ordinary connections yet.
v0.4.10 follows on October 7 with a data-integrity advisory: inserts inside a transaction could silently corrupt a table b-tree, and UPDATE ... FROM lost or repeated updates. v0.4.12, on October 13, fixes two defects v0.4.10 introduced: a join that returned no rows, and row loss on :memory: databases with autocommit_retain = OFF.
v0.4.13 and more data-integrity fixes
v0.4.13 ships on November 1 for all 26 public crates. Among its fixes: an unparenthesized column DEFAULT swallowed a following NOT NULL or COLLATE, also on schemas stock SQLite created, and concurrent writers could commit duplicate implicit rowids.
Its release gate ran the complete storage and SQL crate suites plus every integration target changed since v0.4.12: 18,126 passing test results, 18 of which returned early at an environment check, and 4 failures, each explained in the changelog. Integration targets unchanged since v0.4.12 were not rerun.
The native WAL stack gains recovery, page snapshots and replica catch-up, none of it reachable from the public Connection yet.
fsqlite shell at a database you already have, or add the crate to a Rust project. It's pre-1.0, so try it on something you can afford to break first.curl -fsSL https://raw.githubusercontent.com/Dicklesworthstone/frankensqlite/main/install.sh | bashcargo add fsqlite && cargo add asupersync --no-default-featuresFrankenSQLite is written by coding agents and steered by one person. The tools below are what keep many agents working on the same codebase without stepping on each other, and they're all open source.
FrankenSQLite is one of the FrankenSuite projects: ground-up Rust rewrites of infrastructure people already depend on, including FrankenTUI, FrankenFS, FrankenLibC and FrankenEngine. They share a runtime (asupersync), a habit of checking themselves against the original, and a lot of the same tooling.
