SQLite WASM Official

This page summarizes the projects mentioned and recommended in the original post on news.ycombinator.com

Our great sponsors
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • WorkOS - The modern identity platform for B2B SaaS
  • SaaSHub - Software Alternatives and Reviews
  • wasi-sqlite

    sqlite3 CLI for a-Shell on iOS

  • Very nice. I built sqlite3 for WASI/a-Shell to use on my iPad (https://github.com/rcarmo/wasi-sqlite) and it still has a few issues, I hope this will help (although right now the biggest issue seems to be that the REPL has some sort of memory leak when run inside WASI).

  • sql.js

  • SQLite was one of the first large C code bases to be ported to the web. Alon Zakai (@kripken, the creator of emscripten), made the first commit to sql.js at the start of 2012 [0]. I got involved two years later, and have been maintaining sql.js since. A lot was added since 2012, but the initial core api with 3 functions 'open', 'exec', and 'close' still works today.

    https://github.com/kripken/sql.js/commit/cebd80648dbd369b348...

  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

    InfluxDB logo
  • cr-sqlite

    Convergent, Replicated SQLite. Multi-writer and CRDT support for SQLite

  • > What I really want to see next is an eventually consistent sync system between browser and server

    Another CRDT + SQLite project as a native extension: https://github.com/aphrodite-sh/cr-sqlite

    Should have a release out here shortly but feel free to browse the code, tests and readme till then to see how it works.

  • datasette-lite

    Datasette running in your browser using WebAssembly and Pyodide

  • There are some amazing things for SQLite in the browser especially if you're looking for ways to host queryable data for cheap.

    I have a hacked up POC experimental version of datasette-lite to be able to look at multi-GB databases at https://github.com/simonw/datasette-lite/pull/49. It uses a hacked up chunk'd lazyFile implementation from emscripten and others to grap pages from Cloudflare R2.

    It's a test with california's unclaimed property records (https://www.sco.ca.gov/upd_download_property_records.html) of a 28GB searching up that guy who owns Twitter: https://datasette-lite-lab.mindflakes.com/index.html?url=htt...

    I think there may be a space for super-large multi-GB files served from static storage being accessible from SQlite as well. Another one would be this full-text search of a 43GB SQLite database of Wikipedia's full text search: http://static.wiki/ . Hearing there's official support for this is awesome and I hope they also might add some provisions for those sticking with POSIX/Emscripten as well.

  • wasm_sqlite_with_stats

    Documentation and demonstration of how to build WASM versions of SQLite with extensions embedded

  • I wrote up how to compile SQLite to WASM and also include an extension: https://github.com/llimllib/wasm_sqlite_with_stats

    You can play with the wasm-compiled extension at the version of the sandbox I compiled here: https://llimllib.github.io/wasm_sqlite_with_stats/

    I tried to be thorough with the writeup, so hopefully it helps somebody if that's something they need.

  • vaxine

    Rich-CRDT database based on AntidoteDB.

  • examples

    Example applications using ElectricSQL. (by electric-sql)

  • Yup, open source (https://github.com/electric-sql) + managed replication-as-service. Some of our service code (eg: infra, control plane) is proprietary.

    Download size depends on the driver (we support different SQLite drivers for different environments). The web is quite heavy as it loads the SQL.js WASM (as a separate file, it’s not bundled). I want to say ~350-400kb total but I need to check and it depends a bit on how you build/bundle and serve it.

    One approach would be to look at the network tab of the browser console when running the web example: https://github.com/electric-sql/examples

  • WorkOS

    The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.

    WorkOS logo
  • kikko

    Powerful SQLite adapter for web, mobile and desktop. Build reactive UI on top of it

  • I am preparing for this! Building https://github.com/kikko-land/kikko that widely supports all the of platforms that have SQLite on it, and allows building reactive interface on top of React/Vue/AngularJS(WIP)/whatever.

    Project is in alpha, and already has support of absurd-sql, wa-sqlite for web; expo, tauri, electron, ionic, React Native.

    I am super excited to add support of official SQLite wasm implementation

  • evolu

    Local-first platform designed for privacy, ease of use, and no vendor lock-in

  • React Hooks library for local-first software with end-to-end encrypted backup and sync using SQLite and CRDT

    https://github.com/evoluhq/evolu

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts