API Reference
@libsql/client
Client for libSQL and Turso databases, compatible with SQLite and supporting embedded replicas.
Official Documentation ↗CompatibilityThis documentation covers version
v0.3. Check the official docs for the latest API surface.Installation
npm
npm install @libsql/clientMethods
No methods match this filter.
The libSQL client works against local files, remote Turso, or embedded replicas with one API.
Key Features
- Local, remote, and embedded replica modes
- Parameterized statements and batches
- HTTP and WebSocket transports
Usage Notes
Pin a version and check the official docs for the API surface you depend on before upgrading.
FAQ
- What is an embedded replica?
- A local SQLite file kept in sync with a remote Turso database, giving local read latency with remote durability.
- How do I migrate from better-sqlite3?
- Replace sync calls with the promise-based client and convert positional placeholders; the SQL dialect stays SQLite-compatible.
- Does batch run atomically?
- When you pass the write or transaction mode, statements commit atomically; otherwise they execute sequentially in one request.
Report a problem with this API docOpens a pre-filled issue on GitHub.