electric-sql/pglite
PGlite is a WASM build of Postgres, enabling embeddable, real-time, and local-first database capabilities in browsers, Node.js, Bun, and Deno without external dependencies.
Core Features
Quick Start
npm install @electric-sql/pgliteDetailed Introduction
PGlite revolutionizes database deployment by compiling PostgreSQL into WebAssembly (WASM), allowing it to run directly within client-side environments like web browsers, or server-side runtimes such as Node.js, Bun, and Deno. This eliminates the need for traditional database server installations, simplifying development for local-first and real-time applications. It offers both ephemeral in-memory operation and persistent storage via IndexedDB or the filesystem, all within a compact 3MB gzipped package. PGlite is ideal for developers seeking to embed a full-featured Postgres database directly into their applications, fostering reactive and highly responsive user experiences.