silos dev
Run a local PostgreSQL backed by PGLite for offline, local-first development with the same engine you deploy.
silos dev starts a local PostgreSQL server backed by PGLite — the same
PostgreSQL engine compiled to WebAssembly that Silos runs in the cloud. It listens on
a local port and persists to a local data directory, so you can develop offline and
against the exact engine you'll deploy to.
silos devBy default this listens on port 5432 and stores data under .silos/data.
Connecting
Point any Postgres client at the local server:
psql "postgres://localhost:5432/postgres"Your application's DATABASE_URL works the same way — set it to the local server
during development and to a Silos connection string in production.
Flags
| Flag | Default | Description |
|---|---|---|
--port <port>, -p | 5432 | Port to listen on. |
--data-dir <path>, -d | .silos/data | Directory for PGLite storage. |
--verbose, -v | off | Enable verbose logging. |
Run on a different port with a project-local data directory:
silos dev --port 5433 --data-dir ./.data --verboseWhy local-first
Because Silos runs a real PostgreSQL engine in WASM, the engine in silos dev is the
same one that serves your deployed databases. That means:
No engine drift
Develop against the same Postgres you deploy — no SQLite stand-ins, no surprises in production.
Fully offline
The local server needs no network connection, so you can work anywhere.
Fast iteration
Spin up a throwaway database in seconds, reset by clearing the data directory.
silos dev is for local development. It does not connect to your cloud databases or
sync state to them. To run schema migrations against the local server, point
silos silo apply at its connection string with
--connection-string.
Resetting local state
The local database lives entirely in the data directory. To start fresh, stop the server and remove that directory:
rm -rf .silos/data