The Current State of SQLite Persistence on the Web: February 2024 Update

August 6, 2025

SQLite is the most widely deployed database in the world. Recently, it has also become a viable option for data persistence in browser-based applications.

There are a few projects bringing SQLite to the web:

  1. SQL.js has been around since 2014 — initially cross-compiling SQLite to JavaScript, then WASM(WebAssembly) when browsers started supporting it. By itself, SQL.js only supports in-memory databases, and does not support persistence other than importing or exporting the entire database file at a time.
  2. In 2021, the wa-sqlite project was created, implementing experimental support for persisting SQLite data in IndexedDB. Its performance was quite slow at that point.
  3. Later in 2021, the absurd-sql project did the same, but using a couple of new techniques to achieve much faster performance — even surpassing direct IndexedDB performance for some query patterns. The accompanying blog post has a lot of details on the complexities of the implementation. While it was a great showcase of what can be done, it was never maintained as a project to be used in production. The wa-sqlite project built further on some of these ideas.
  4. Towards the end of 2022, the official SQLite project released their own beta WASM build.

Side note: there is also the Web SQL project which has built-in support in Chrome and older versions of Safari. It had too many limitations and difficulties to be a cross-browser standard, and is being phased out. For that reason, we’re not exploring it any further in this post.

While none of these projects currently claim “production level stability” for persistence, the current support could already be sufficient for some projects. But there are many options to choose from, and pros and cons may not be immediately clear.

This post gives an overview of the various considerations involved in persisting SQLite data in a browser, with details about each currently available implementation. If you’re only interested in learning what to use right now, skip to the “Recommendations” section at the end of the post.

Concurrency in SQLite

Source: The Current State of SQLite Persistence on the Web: February 2024 Update

With the local first architecture gaining traction, the challenge of storing data on the client is central. While we’ve long had localStorage and IndexedDB, the former is not really designed for significant amounts of data storage, and the latter is a lower level API, and both are different architecturally from how many fold are storing their data online, which will often be some form of SQL.

While years ago we had SQL in the browser with WebSQL (RIP), this has long been deprecated but there are an increasingly number of implementations of SQL in the browser for persistent storage that this in depth article details.