plateauDB
The browser database that stays fast at a million rows.
A local database for web apps, written in Rust and WebAssembly. Queries cost the size of the answer, not the size of the table, so your app feels the same with 10k records or 1M.
At 1M rows plateauDB is 88× faster than the browser's built-in IndexedDB, and its line barely moves. That flat line is the name.
Against the browser's built-in IndexedDB at 1M rows in Chromium 158, with WebKit (Safari's engine) alongside. Medians of 20 runs on an Apple M5 Max.
Use cases
For apps that keep a lot of data in the browser
IndexedDB is fine at a few thousand records. Past that, every filter that does not match one index walks the table row by row. plateauDB is for the apps that hit that wall.
Local-first apps
Issue trackers, CRMs and project tools that sync a whole workspace to the device and filter it as you type.
assignee = me AND label = bug AND priority ≤ 2Offline-first apps
Mail, notes and field apps that keep working on a plane, with hundreds of thousands of records on the device.
folder = inbox ORDER BY receivedAt DESC LIMIT 50Big client-side views
Data grids, dashboards and faceted filters over a million rows, with no round trip to a server for every click.
COUNT where team = 7 AND updatedAt > lastWeekMoving off IndexedDB
Already on IndexedDB? Swap the factory and keep your code. Declare the fields you filter on to unlock fast queries.
const db = plateau.open("app", 1)How it works
It does less work, so it stays flat
IndexedDB answers a filter by walking one index and checking every other field row by row. plateauDB keeps a ready-made answer for every value of every field and combines them.
A bitmap for every value
Each field you declare keeps a compressed set of the rows holding each value. A filter on three fields is three sets ANDed together, so the cost follows the answer, not the table.
Reads only what it needs
Data lives in the Origin Private File System. Opening reads a small manifest; columns, indexes and rows load on first touch, within a memory budget you set.
Off the main thread
A Rust engine compiled to WebAssembly runs in a worker with synchronous file access. Your app calls the familiar IndexedDB API, and each transaction crosses in one message.
Developer experience
A familiar API. One superpower.
plateauDB speaks the standard IndexedDB API, so existing code moves over unchanged. Declare the fields you filter on as columns, and query them with store.query.
- The IndexedDB API you know: stores, indexes, cursors, transactions, events
- Passes 84 of 85 IndexedDB conformance tests in Chromium and WebKit
- One addition, store.query, for filters, sorting, limits and counts
- Crash-safe commits, and a memory budget for low-end devices
- No COOP/COEP headers needed. The worker and WASM start themselves
On npm as 0.2.0. Install with npm i plateaudb. It is pre-1.0: the API can still change, and the source is on GitHub.
import { plateau, promise } from "plateaudb";
const open = plateau.open("tracker", 1); // same as indexedDB.open
open.onupgradeneeded = () => {
open.result.createObjectStore("issues", {
keyPath: "id",
// the one addition: declare the fields you filter or sort on
columns: {
id: "f64",
teamId: { kind: "u32", index: "bitmap" },
stateId: { kind: "u32", index: "bitmap" },
assigneeId: { kind: "u32", index: "bitmap" },
labelIds: { kind: "u32_multi", index: "bitmap" },
priority: { kind: "u32", index: "bitmap" },
updatedAt: { kind: "f64", index: "ordered", group: "teamId" },
},
});
};
const db = await promise(open);Benchmarks
Fast where IndexedDB is slow. Honest where it isn't.
A Linear-style issue tracker with teams, states, assignees, labels and priorities. Same data, same results from every engine. Pick a browser and a table size.
Bars are to scale within each row. Times are medians of 20 runs on an Apple M5 Max, measured from the main thread, so plateauDB and SQLite include the trip to their worker.
Compare
Where it fits
The nearest options each give up one thing plateauDB aims to keep: the IndexedDB API, fast multi-field filters, or OPFS storage.
| plateauDB | IndexedDB | Dexie | SQLite-WASM | |
|---|---|---|---|---|
Speaks the IndexedDB API Dexie wraps IndexedDB in its own API; SQLite speaks SQL | ||||
Fast filters on any mix of fields IndexedDB uses one index per query; Dexie can use compound indexes | ||||
Stays flat as the table grows | ||||
Stores data in OPFS | ||||
No special server headers | ||||
Several tabs at once planned for plateauDB | ||||
Production-ready plateauDB is an experiment |
Facts about other projects come from their own documentation, read in November 2026. Dexie was not benchmarked.
Status
Early, and honest about it
- Engine and query plannerDoneBitmaps, grouped ordered indexes, lazy file reads
- IndexedDB-compatible APIDone84 of 85 conformance tests in Chromium and WebKit
- Crash-safe writesDoneUpdates, deletes and compaction, tested across 1,410 crash points
- Faster page start-upNextClose the gap with IndexedDB on a fresh page load
- Several tabsDoneOne owning worker, the other tabs routed to it
- Published packageDoneplateaudb 0.2.0 on npm, MIT licensed
- Fallback to IndexedDBDoneUses the browser's own IndexedDB where OPFS, workers or WebAssembly are missing