tursodatabase /libsql
libSQL is a fork of SQLite that is both Open Source, and Open Contributions.
★ 17,332⑂ 562👁 84⑃ 1,595● 651▤ 55
+2
日增长
+27
周增长
+52
月增长
17,332
stars
562
forks
84
watchers
1,595
prs
651
issues
55
releases
README
libSQL
libSQL is an open source, open contribution fork of SQLite, created and maintained by Turso.
libSQL Docs ·
libSQL Manifesto ·
Turso ·
Turso Docs ·
Discord ·
Blog & Tutorials
---
[!IMPORTANT]
Turso database and libSQL are two different projects from the same team.
libSQL (this repository) is an open-source fork of SQLite. It extends SQLite with features like embedded replicas and remote access, but inherits SQLite's fundamental limitations such as the single-writer model.
Turso database is a SQLite-compatible database rewritten from scratch in Rust. It is not a fork of SQLite — it is a completely new implementation that goes beyond what any SQLite fork can offer, including concurrent writes and bi-directional sync with offline support. Turso is currently in beta.
If you're starting a new project, you probably want to look into Turso. libSQL is actively maintained, but new features are being developed in Turso.
Documentation
We aim to evolve it to suit many more use cases than SQLite was originally designed for, and plan to use third-party OSS code wherever it makes sense.
libSQL has many great features, including:
Embedded replicas that allow you to have replicated database inside your app.
libSQL server for remote SQLite access, similar to PostgreSQL or MySQL
Supports Rust, JavaScript, Python, Go, and more.
There are also various improvements and extensions to the core SQLite:
ALTER TABLE extension for modifying column types and constraints
Randomized ROWID
WebAssembly User Defined Functions
Pass down SQL string to virtual table implementation
Virtual write-ahead log interface
The comprehensive description can be found here
Official Drivers
TypeScript / JS
Rust
Go
Go (no CGO)
Experimental Drivers
Python (experimental)
C (experimental)
Community Drivers
PHP
D (experimental, based on the C driver)
Ring (experimental, based on the C driver)
GUI Support
Beekeeper Studio — macOS, Windows, and Linux
Outerbase — Runs in the browser
TablePlus — macOS, Windows, and Linux
Dataflare — Paid (with limited free version) macOS, Windows, and Linux
libSQL Studio - Runs in the browser
Getting Started
The project provides two interfaces: the libSQL API, which supports all the features, and the SQLite C API for compatibility.
To build the SQLite-compatible C library and tools, run:
sh
cargo xtask build
To run the SQL shell, launch the libsql program:
console
$ cd libsql-sqlite3 && ./libsql
libSQL version 0.2.1 (based on SQLite version 3.43.0) 2023-05-23 11:47:56
Enter ".help" for usage hints.
Connected to a transient in-memory database.
Use ".open FILENAME" to reopen on a persistent database.
libsql
Docker
To run libSQL using docker, refer to the Docker Docs
Why a fork?
SQLite has solidified its place in modern technology stacks, embedded in nearly any computing device you can think of. Its open source nature aTop issues
#1121LibsqlError: URL_INVALID when deploying to Render30 comments · 2024-03-03#1607ERROR libsql::replication: replicator sync | database disk image is malformed17 comments · 2024-07-25#976Support changing the encryption key in libsql-server12 comments · 2024-02-01#1804Namespaces not available in replica11 comments · 2024-10-31#11Push free page management down to the VFS layer10 comments · 2022-10-04#1781Memory leak, Dockerized on Railway9 comments · 2024-10-06#1203I keep getting `HRANA_WEBSOCKET_ERROR: WebSocket was closed`8 comments · 2024-03-13#2254Database getting corrupted on power loss7 comments · 2026-07-09
Discussions
#2308why `npm install @libsql/client` will remove other modules?1 comments · 2026-11-01#2209Support for LATERAL joins?0 comments · 2026-01-09#2183Are sync & offline use paid Turso features?1 comments · 2025-10-29#2157sqlite3 type cli client?0 comments · 2025-09-04#2140Add tag/topic `libsql` to this GH repo0 comments · 2025-08-04#2139Why dot product isn't available?1 comments · 2025-08-04#2120Add HA support for libsqld using Kubernetes StatefulSet and Leader Election with Lease API1 comments · 2025-07-09#2086Instructions for wasm build?2 comments · 2025-05-30
Latest release
libsql-server-v0.24.32 libsql-server-v0.24.32 2025-02-14Install libsql-server 0.24.32 Install prebuilt binaries via shell script sh curl --proto '=https' --tlsv1.2 -LsSf https://github.com/tursodatabase/libsql/releases/download/libsql-server-v0.24.32/libsql-server-installer.sh | sh Install prebuilt binaries via Homebrew sh brew install libsql/sqld/sqld Download libsql-server 0.24.32 | File | Platform | Checksum | |--------|----------|----------| | libsql-server-aarch64-apple-darwin.tar.xz | Apple Silicon macOS | checksum | | libsql-server-x86_64-apple-darwin.tar.xz | Intel macOS | checksum | | libsql-server-aarch64-unknown-linux-gnu.ta