qmetrics.net

sql.js

SQLite compiled to JavaScript and WebAssembly

DatabasesDesktop/CLI app
sql.js screenshot

sql.js runs SQLite in the browser or Node.js via WebAssembly. You can create in-memory databases, import existing .sqlite files, and export results as typed arrays.

Overview

sql.js is a JavaScript SQL database built by compiling SQLite to WebAssembly with Emscripten. It lets you instantiate a relational database entirely in JavaScript, run CREATE and SELECT statements, and work with prepared statements, custom functions, and aggregates in process memory.

By default the active database lives in memory, so changes are not persisted unless you export the file bytes. You can load an existing SQLite file from user input, fetch, or disk in Node.js, and write the database back out as a Uint8Array when finished.

Browser use loads a separate .wasm asset or an inline build that embeds the binary. Node.js installs from npm and can read and write database files on disk after export. A Web Worker variant offloads heavy queries from the main thread, and builds include production, debug, and browser-targeted flavors.

The documentation notes that native SQLite bindings are preferable for Electron or Node when you need direct file access and better performance; sql.js fits interactive browser demos, client-side analytics, and portable SQLite experimentation without a server database.

Key features

  • WebAssembly SQLite engine
  • In-memory database by default
  • Import and export SQLite file bytes
  • Prepared statements and binding
  • Custom SQL functions and aggregates
  • Web Worker build option
  • Inline single-file wasm bundle
  • Node.js npm package

Use cases

  • Browser-side SQL prototyping
  • Client-side SQLite file inspection
  • Teaching SQL without a server
  • Offline demo interpreters
  • Node scripts with wasm SQLite

Tags

Similar software

Supabase

Open-source Postgres platform with auth, APIs, and storage

Supabase bundles a dedicated Postgres database with authentication, auto-generated REST and GraphQL APIs, realtime, functions, file storage, and vector tooling.

★ 115.6k⟳ todayApache-2.0
Open Source Alternative to:FirebaseFirebase Realtime Database

Prometheus

Open-source metrics monitoring and time series database

Prometheus collects metrics from configured targets, evaluates rules, and can raise alerts. It stores time series data and exposes a query language called PromQL.

★ 67.9k⟳ yesterdayApache-2.0
Open Source Alternative to:PRTG Network Monitor

NocoDB

Self-hostable no-code database with spreadsheet interface

NocoDB turns Postgres, MySQL, SQLite, or a hosted database into editable tables with grid, kanban, form, gallery, and calendar views. Teams collaborate with roles, sharing, REST APIs, and workflow integrations.

★ 65.6k⟳ todaySource-available
DatabasesSelf-hostable

etcd

Raft-backed distributed consistent key-value store

etcd stores small critical configuration and coordination data for clusters. It exposes a gRPC API, tolerates failures via Raft, and ships with the etcdctl command-line client.

★ 52.7k⟳ 3 days agoApache-2.0
DatabasesSelf-hostable

DBeaver

Universal multi-platform database tool and SQL client

Free desktop client for developers and DBAs with SQL editing, data editing, ER diagrams, exports, and support for hundreds of JDBC or ODBC databases.

★ 52.6k⟳ todayApache-2.0
DatabasesDesktop/CLI app
Open Source Alternative to:DataGripNavicat+2

ClickHouse

Column-oriented real-time analytics database management system

ClickHouse is a column-oriented database for generating analytical reports in real time using SQL on large datasets.

★ 51.2k⟳ todayApache-2.0
Open Source Alternative to:Amazon Redshift