
sqlite3_rsync: Use It for Low-Disk SQLite Snapshots
Verdict: Use it. SQLite's own docs put a 500MB sync near 20KB of traffic, and the copy needs no local duplicate.
Bottom line: Use it. sqlite3_rsync copies a consistent SQLite snapshot over SSH without first writing a local duplicate, which is the disk-space cost of the backup API and VACUUM INTO. SQLite's own docs put a 500MB sync near 20KB of traffic. Install version 3.50.0 or later on both ends first.
The Weights Desk · 3 min read- The bottom line: Use it, provided SQLite 3.50.0 or later is installed on both machines.
- The deciding number is SQLite's own figure: a 500MB database will typically synchronize with about 20KB of network traffic.
- Unlike the backup API or VACUUM INTO, it can send a snapshot over SSH without first building a full local copy, per Simon Willison.
- Both databases can stay live: the replica ends up as a consistent snapshot of the origin at the moment the command started.
- Mixing 3.50.0+ locally with 3.49.1 or older remotely can hang; the docs say to upgrade both sides or pass --protocol 1.
Bottom line: Use it. sqlite3_rsync is worth adding to a SQLite operator's toolbox because it can ship a consistent snapshot to another machine without first creating a full local duplicate. That is the property Simon Willison highlighted on 26 November 2026, and the SQLite documentation backs the efficiency side with a concrete figure. The tool is not new: it arrived as experimental in SQLite 3.47.0 in October 2024 and was enhanced in 3.50.0 in May 2025. What changed is the framing, which is disk headroom rather than bandwidth.
The problem it removes: the duplicate copy
The standard ways to snapshot a SQLite file, the backup API and VACUUM INTO, both need enough free disk to hold a second copy of the database. Willison points out that a small instance already using more than half its disk is simply out of luck. sqlite3_rsync, by his account, can copy a snapshot over an SSH connection to another machine without first building that full local copy. His post argues this conceptually and reports no disk measurements of its own.
The number that decides it: about 20KB
The SQLite documentation says that when origin and replica are similar, traffic is often less than 0.01% of database size, and that a 500MB database will typically synchronize with about 20KB. The mechanism is hash exchange: the replica sends hashes of pages or page groups, and the origin returns only content that differs. Before 3.50.0, only single-page hashes were sent, so even identical databases cost at least about 0.5% of database size. Treat the 20KB as the documentation's typical case, not a guarantee.
Live databases are allowed
The documentation states that both databases may be live: other programs can write to the origin and read from the replica during the run. The replica becomes a copy of the origin as it existed when the command started, and later origin changes are not transferred. While it runs the replica is read-only. The same page warns that plain rsync does not understand SQLite transactions and can produce a corrupt copy, which is the failure this tool is built to avoid.
Where it breaks: versions and limits
Version mismatch is the main operational trap. The efficient protocol needs SQLite 3.50.0 or later on both sides, and pairing a newer local build with 3.49.1 or older remotely can hang; the documented fixes are upgrading both ends or passing --protocol 1. The tool handles one database per invocation with no wildcards, and at least one side must be local. The replica's header may differ, including the change counter, so do not compare whole files byte for byte.
The bottom line: Use it
Bottom line: Use it for off-box snapshots and replica refreshes of SQLite files, especially on disks that cannot hold a duplicate. The sourced evidence is the documented 20KB-per-500MB typical traffic and the removal of the local-copy requirement. What we could not verify here is real-world runtime or load on a busy origin, since neither source reports such a benchmark. Before depending on it, pin 3.50.0 or later on both machines and time a restore from a replica on your own data.
- Why use sqlite3_rsync instead of the backup API or VACUUM INTO?
- Simon Willison notes that both of those need enough free disk to hold a duplicate of the database. sqlite3_rsync can send a snapshot over SSH to another machine without creating that local duplicate first, which matters on small instances that are more than half full.
- Is it safe to run against a database that is being written to?
- According to the SQLite documentation, yes. Both databases may be live, and the replica becomes a consistent snapshot of the origin as it existed when the command started. Later origin writes are not transferred, and the replica is read-only during the run.
- What version do I need?
- SQLite 3.50.0 (2025-05-29) or later on both sides for the efficient protocol. The WAL-mode and identical-page-size requirements were removed in that release. Mixed versions can hang unless you pass --protocol 1.
- What are the main limits?
- One database per invocation, no wildcards, and at least one side must be local. The replica's header may differ from the origin's, for example the change counter.