Rust-powered core via N-API. Zero dependencies. ACID durability. 2M+ reads per second. Built for production.
Everything you need in a production-ready JSON database, with zero external dependencies.
Core logic in Rust via N-API delivers ~2M ops/s reads and ~260k ops/s writes. Lock-free architecture ensures readers never block writers, maximizing multicore efficiency.
OS-level advisory file locking prevents data corruption across multiple processes.
Group Commit Write-Ahead Logging ensures data integrity with near-zero overhead.
In-memory Map indices provide instant lookups regardless of dataset size.
Adaptive parallelism using Rayon automatically scales with your CPU cores.
Built-in encryption for data at rest. Protect sensitive data without external libraries.
Auto-expire keys after a specified time. Perfect for sessions and caches.
EventEmitter-style subscriptions to data changes with pattern matching.
Simple API designed for developer productivity without sacrificing performance.
# Using bun (recommended)
bun add jsondb-high
# Using npm
npm install jsondb-high
import JSONDatabase from 'jsondb-high';
// Initialize
const db = new JSONDatabase('db.json');
// Write data
await db.set('user.1', {
name: 'Alice',
role: 'admin'
});
// Read data
const user = await db.get('user.1');
console.log(user);
Benchmarked against real-world workloads. Consistently outperforms alternatives.
Near-instant reads with lock-free architecture
Sustained writes with Group Commit WAL
O(1) lookups regardless of dataset size
Sub-millisecond response times
Four durability modes to match your performance and safety requirements.
| Mode | Throughput | Latency | Durability Window | Best For |
|---|---|---|---|---|
none |
~260k ops/s | 0.003ms | Manual save only | Caching, temp data |
lazy |
~200k ops/s | 0.003ms | 100ms | Development |
batched (Recommended) |
~240k ops/s | 5ms | 10ms | Production workloads |
sync |
~2k ops/s | 0.5ms | Immediate | Financial data |