# sled

> Pure-Rust embedded key-value database with a BTreeMap-like API and ACID transactions

Source: https://talira.ai/catalog/sled-2yqmkzh2
Every listing: https://talira.ai/catalog.md

- Kind: Open source
- Types: Library, Database
- Categories: [databases / embedded](https://talira.ai/categories/databases/embedded)
- Licence: MIT OR Apache-2.0[^3]
- Pricing: Free and open source[^3]
- Free tier: yes[^3]
- Creator: Tyler Neely

sled is a lightweight, high-performance embedded transactional database written in pure Rust, with an API like a thread-safe BTreeMap of byte keys to byte values. It has serializable ACID transactions across keys and keyspaces, atomic single-key operations including compare-and-swap, zero-copy reads, write batches, subscriptions to changes on key prefixes, multiple keyspaces, merge operators, range iterators, a crash-safe ID generator and optional zstd compression, on lock-free, flash-optimized log-structured storage. Its author calls it beta: the latest stable release is 0.34.7, and the main branch holds a large rewrite published as 1.0 alphas.

## Links

- GitHub: https://github.com/spacejam/sled
- Docs: https://docs.rs/sled/

## Problems it solves

- store key-value data on disk inside my Rust app without running a database server
- use an embedded database with ACID transactions in pure Rust
- replace RocksDB or LMDB bindings with a pure-Rust embedded store
- watch for changes to keys with a prefix in an embedded Rust database

## Features

- BTreeMap-like API over byte keys and values
- Serializable ACID transactions across keyspaces
- Atomic compare-and-swap
- Zero-copy reads
- Write batches
- Subscriptions to key prefix changes
- Multiple keyspaces
- Merge operators
- Forward and reverse range iterators
- Crash-safe monotonic ID generator
- Optional zstd compression
- Lock-free, flash-optimized log-structured storage

## Limitations

- Beta: the latest stable release is 0.34.7, and the main branch holds a large in-progress 1.0 rewrite published only as alphas.[^1][^2]
- Doesn't support opening the same database from several instances at once.[^1]

## Trust

Overall: 0.42 out of 1.
Signals: maintenance 0.27, adoption 0.79, momentum 0.56, community 0.76, backing 0.20, extensibility 0.00.

- latest release v0.34.7 5.2 years ago
- 9.1k GitHub stars
- 80 contributors
- created by Tyler Neely

Warnings:

- last commit 7 months ago

## Alternatives

- [RocksDB](https://talira.ai/catalog/rocksdb-2613tyv8.md): Embeddable persistent key-value store for fast storage
- [LMDB](https://talira.ai/catalog/lmdb-mmsatwjv.md): Lightning Memory-Mapped Database: a tiny, crash-proof embedded key-value store
- [Turso Database](https://talira.ai/catalog/turso-database-hm0yb33f.md): An in-process SQL database written in Rust, compatible with SQLite, now with a Postgres frontend too

## Sources

[^1]: https://github.com/spacejam/sled (checked 26 Nov 2026)
[^2]: https://crates.io/crates/sled (checked 26 Nov 2026)
[^3]: https://github.com/spacejam/sled/blob/main/Cargo.toml (checked 26 Nov 2026)
