NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
npm · #3499 most downloaded on npm
PGlite is a WASM Postgres build packaged into a TypeScript client library that enables you to run Postgres in the browser, Node.js and Bun, with no need to install any other dependencies. It is only 3.7mb gzipped.
Last release 1 months ago
26 Aug 2026
Release timing varies
gaps range from 8 days to 2 months
Nearly every release is documented
notes for 54 of 59 stable releases
Nothing withdrawn
no release was ever pulled
3 years old
78 releases · first in 2024
Updated dependencies [ c771db3 ]
Updated dependencies [ 2f9cf75 ]
One column per month.
Nothing published for this version
a290741: Reset retained protocol parser state after a malformed backend message so later queries can recover.
PGlite.create({ fs }) on a fresh database calling the provided filesystem's init() twice: the inner initdb instance no longer inherits the user-provided fs and always runs on its own scratch filesystem. Previously any VFS holding exclusive resources (e.g. OPFS sync access handles) failed with a contention error on first create.formatQuery (used by live.query/live.incrementalQuery to inline parameters) emitting %NL instead of the positional %N$L format specifier. A bare %NL is "min width N" and consumes format() arguments sequentially, so placeholders that are out of textual order silently bound the wrong values, and repeated placeholders failed with too few arguments for format().Results: command (e.g. SELECT, INSERT, CREATE), and rowCount (the per-statement count from the tag). The tag was already received and parsed internally to compute affectedRows, but these values were not surfaced. Matching node-postgres' command/rowCount result fields lets pg-compatible adapters report them without re-parsing SQL.process.exitCode when closing a PGlite instance. close() calls _emscripten_force_exit(0), whose Emscripten runtime sets process.exitCode = 0, clobbering any exit code the host process had already set. This mirrors the existing save/restore guards in #init() and execProtocolRaw(), so closing a database no longer silently resets the host process's exit code.7e0d6d1: Detect the Node environment via process.type instead of process.versions.electron. The previous Electron guard (#951) also treated the Electr
process.type instead of process.versions.electron. The previous Electron guard (#951) also treated the Electron main and utility processes as non-Node, which broke PGlite's filesystem code path there. process.type only excludes Electron's web contexts (renderer, web worker, service worker), so PGlite keeps using the Node.js path in the Electron main and utility processes. Follow-up to #951 / #813.2ccbb4c: Improve parsing/raw results handling
21fc995: fix serializing arrays of BigInts
930e2d0: fix PGlite version; redeploy external extensions
93d50aa: Upgrade to Postgres 18.3; move other extensions to their own npm packages;
Nothing published for this version
@electric-sql/pglite-pgvector@0.0.6
@electric-sql/pglite-pgvector@0.0.5
@electric-sql/pglite-pgvector@0.0.4
@electric-sql/pglite-pgvector@0.0.3
@electric-sql/pglite-pgvector@0.0.2
408500c: Allow passing in onError to 'syncShapesToTables'
### Patch Changes - Updated dependencies [ce0e74e] - @electric-sql/pglite@0.3.12
### Patch Changes - Updated dependencies [9a104b9] - @electric-sql/pglite@0.3.11
8785034: Added pg_uuidv7 extension.
ad3d0d8: Updated pg_dump to use callback data exchange; built pg_dump with emscripten
ce0e74e: Added pgTAP extension.
9a104b9: Added dict_int, dict_xsyn, file_fdw, intarray, pageinspect, pg_buffercache, pg_freespacemap, pg_surgery, pg_visibility, pg_walinspect, unacce
ad765ed: initdb calls system to query the server configs. avoid that by hardcoding a return value of 123
### Patch Changes - e40ccad: Upgrade emsdk
f12a582: Ensure MessageContext and its children are actually cleared between queries
0936962: nested exception bugfix; wasm runtime exception fix
469be18: bug fix in packaging the distribution
### Patch Changes - Updated dependencies [c6bddde] - @electric-sql/pglite@0.4.5
### Patch Changes - Updated dependencies [b88c5c3] - @electric-sql/pglite@0.4.4
### Patch Changes - Updated dependencies [2ae666f] - Updated dependencies [fb95e66] - Updated dependencies [65fc101] - @electric-sql/pglite@0.4.3
### Patch Changes - Updated dependencies [41632c4] - @electric-sql/pglite@0.4.2
### Patch Changes - Updated dependencies [37fb39e] - @electric-sql/pglite@0.4.1
initialInsertMethod option that can specify insert, csv or json as the method used to handle the initial sync. The supersedes the useCopy option which is now deprecated and will be removed in a future version.97e52f7: upgrade to postgresql 17.4
0033bc7: Fix a race condition in live query unsubscription that could result in live queries failing to update.
97e52f7: upgrade to postgresql 17.4
### Patch Changes - Updated dependencies [ce0e74e] - @electric-sql/pglite@0.3.12
commitGranularity parameter in the syncShapeToTable function, enabling the user to choose how often the sync should commit.syncShapeToTable### Patch Changes - Updated dependencies [9a104b9] - @electric-sql/pglite@0.3.11
.transaction methodrefreshArrayTypes() call to re-sync newly created complex array columns, like enums### Patch Changes - Updated dependencies [ad765ed] - @electric-sql/pglite@0.3.10
### Patch Changes - e40ccad: Upgrade emsdk - Updated dependencies [e40ccad] - @electric-sql/pglite@0.3.9
runExclusive method on PGlite that allows you to hold an exclusive lock on the database, for use with execProtocol* methodsexecProtocolRawSync method that can execute a postgres wire protocol synchronouslyoffset and limit option to live queries, when used it will return the total count for the query along with efficient updating of the offset. This works well with windowed or virtualised scrolling components.offset and limit option to live queries, when used it will return the total count for the query along with efficient updating of the offset. This works well with windowed or virtualised scrolling components.electric.syncing config flag in Postgres during a sync transaction to enable user defined triggers to chose how to run during a sync.DELETE FROM rather than a TRUNCATE on must-refetch so that custom merge logic can be applied with triggers.useCopy option to syncShapeToTable, when true performs a COPY TO for the initial sync.be677b4: fix pg_dump on Windows systems
be677b4: fix pg_dump on Windows systems
When calling pg_dump on Windows system the function fails with an error as the one bellow.
❗ Notice the double drive letter
Error: ENOENT: no such file or directory, open 'E:\C:\Users\<USERNAME>\AppData\Local\npm-cache\_npx\ba4f1959e38407b5\node_modules\@electric-sql\pglite-tools\dist\pg_dump.wasm'
The problem is in execPgDump function at line
const blob = await fs.readFile(bin.toString().slice(7))
I think the intention here was to remove file:// from the begging of the path. However this is not necesarry readFile can handle URL objects.
Moreover this will fail on Windows becase the slice creates a path like '/C:/<USERNAME>...' and the readFile function will add the extra drive letter
Updated dependencies [f12a582]
Updated dependencies [bd263aa]
describeQuery method to get type information about a query's parameters and result fields without executing it.limit 1 it would return no rowsPGliteOptions. Added custom serializer option to QueryOptions.useLiveQuery. This allows you to create a live query in a react-router loader, then pass it to the route component where it is then attached with useLiveQuery.### Patch Changes - Updated dependencies [0936962] - @electric-sql/pglite@0.3.7
util to package.json browser config to exclude it in browser builds### Patch Changes - Updated dependencies [6898469] - Updated dependencies [469be18] - Updated dependencies [64e33c7] - @electric-sql/pglite@0.3.6
### Patch Changes - 8172b72: new pg_dump wasm blob - Updated dependencies [6653899] - Updated dependencies [5f007fc] - @electric-sql/pglite@0.3.5
38a55d0: fix cjs/esm misconfigurations
@electric-sql/pglite-pg_hashids@0.0.6
@electric-sql/pglite-pg_hashids@0.0.5
29f5617: Handle PostgreSQL CancelRequest wire protocol messages
29f5617: Handle PostgreSQL CancelRequest wire protocol messages
Added support for the CancelRequest message that some clients and connection proxies send during the connection startup phase. PGlite has no backend process to cancel, so the request is consumed and silently ignored (the protocol expects no response), which prevents it from being misinterpreted as a malformed startup/typed message. This complements the existing SSLRequest handling.
### Patch Changes - Updated dependencies [a290741] - Updated dependencies [6b6f28d] - Updated dependencies [354f4ae] - Updated dependencies [219af1e]
### Patch Changes - Updated dependencies [7e0d6d1] - @electric-sql/pglite@0.5.4
7f6ee05: Handle the SSLRequest startup packet per the PostgreSQL wire protocol: when SSL is not available, respond with N so the client may continue w
SSLRequest startup packet per the PostgreSQL wire protocol: when SSL is not available, respond with N so the client may continue with a cleartext StartupMessage. Improves interoperability with JDBC clients such as DBeaver that probe TLS first without requiring manual SSL mode tweaks. See https://www.postgresql.org/docs/current/protocol-message-formats.html .@electric-sql/pglite-pg_hashids@0.0.3
@electric-sql/pglite-pg_hashids@0.0.2
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Your coding agent can read these notes before it upgrades. Set up the MCP server →