benbjohnson/litestream

Streaming replication for SQLite.

Go

14,482

738 commits

updated Oct 9, 2026

See the code

See what people are saying

SourceMessageScoreDate

Litestream: Streaming Replication for SQLite

1

Oct 12, 2026

README

Litestream GitHub release (latest by date) Status GitHub Docker Pulls

Litestream is a standalone disaster recovery tool for SQLite. It runs as a background process and safely replicates changes incrementally to another file or S3. Litestream only communicates with SQLite through the SQLite API so it will not corrupt your database.

If you need support or have ideas for improving Litestream, please visit GitHub Issues. Please visit the Litestream web site for installation instructions and documentation.

If you find this project interesting, please consider starring the project on GitHub.

Source database changes

When Litestream begins replicating a database, it creates an internal _litestream_lock table in the source SQLite database. This is expected and safe to leave in place. Litestream uses the table to acquire SQLite's write lock while coordinating synchronization around WAL checkpoints. The writes occur in transactions that are rolled back, so Litestream does not leave rows in the table.

The table is part of the source database, not a separate table in the replica destination. Because the source schema is backed up, restored databases also contain it. Its creation changes the source database schema and can change its page count or bytes, so a database under Litestream should not be expected to remain byte-identical to its pre-Litestream state.

Do not drop _litestream_lock while Litestream is running. Synchronization around a checkpoint can fail until Litestream reinitializes the database. Restarting Litestream recreates the missing table automatically.

Contributing

We welcome bug reports, fixes, and patches! Please see our Contributing Guide for details on how to contribute.

Security

Please do not open a public issue for security vulnerabilities. Report them privately through GitHub's private vulnerability reporting, which keeps the report visible only to you and the maintainers until a fix is released. See our Security Policy for what to include and what to expect.

Acknowledgements

I want to give special thanks to individuals who invest much of their time and energy into the project to help make it better:

Huge thanks to fly.io for their support and for contributing credits for testing and development!

replication
s3
sqlite

benbjohnson/litestream

Streaming replication for SQLite.

Go

14,482

738 commits

updated Oct 9, 2026

See the code

See what people are saying

SourceMessageScoreDate

Litestream: Streaming Replication for SQLite

1

Oct 12, 2026

README

Litestream GitHub release (latest by date) Status GitHub Docker Pulls

Litestream is a standalone disaster recovery tool for SQLite. It runs as a background process and safely replicates changes incrementally to another file or S3. Litestream only communicates with SQLite through the SQLite API so it will not corrupt your database.

If you need support or have ideas for improving Litestream, please visit GitHub Issues. Please visit the Litestream web site for installation instructions and documentation.

If you find this project interesting, please consider starring the project on GitHub.

Source database changes

When Litestream begins replicating a database, it creates an internal _litestream_lock table in the source SQLite database. This is expected and safe to leave in place. Litestream uses the table to acquire SQLite's write lock while coordinating synchronization around WAL checkpoints. The writes occur in transactions that are rolled back, so Litestream does not leave rows in the table.

The table is part of the source database, not a separate table in the replica destination. Because the source schema is backed up, restored databases also contain it. Its creation changes the source database schema and can change its page count or bytes, so a database under Litestream should not be expected to remain byte-identical to its pre-Litestream state.

Do not drop _litestream_lock while Litestream is running. Synchronization around a checkpoint can fail until Litestream reinitializes the database. Restarting Litestream recreates the missing table automatically.

Contributing

We welcome bug reports, fixes, and patches! Please see our Contributing Guide for details on how to contribute.

Security

Please do not open a public issue for security vulnerabilities. Report them privately through GitHub's private vulnerability reporting, which keeps the report visible only to you and the maintainers until a fix is released. See our Security Policy for what to include and what to expect.

Acknowledgements

I want to give special thanks to individuals who invest much of their time and energy into the project to help make it better:

Huge thanks to fly.io for their support and for contributing credits for testing and development!

replication
s3
sqlite

Project health

Overall

5.8/10

Maintained

10/10

Code review

7/10
OpenSSF Scorecard

Latest release

v0.5.17 · Aug 31, 2026

Releases this year

18

Significant stargazers

(top 24 of 357)

Matteo Collina

11,397 followers · starred Jan 2022

Anas Khan

400 followers · starred Aug 2026

Simon Cruanes

467 followers · starred Oct 2021

Matt Layher

2,098 followers · starred Jan 2021