pgStack

The Complete PostgreSQL Backend

Auth, REST, live SQL queries, edge functions, storage, a job queue, auto-HTTPS and a Studio dashboard.
Two processes. One command.

$ npx pgstack init myapp && cd myapp && pgstack dev

Nine pillars. Zero glue code.

Everything you need to build and ship a production backend, powered entirely by PostgreSQL.

Security-first auth

Email/password (argon2id), OAuth, magic links, JWT. Row-Level Security on every request via a two-pool least-privilege model — hardened against 26 documented trust-boundary invariants.

REST API

PostgREST-compatible CRUD with filters, embedding, RPC, and auto-generated OpenAPI. Zero boilerplate.

Live Queries

SQL-level reactivity via pg_reactive. Column-level change tracking, delta computation over WebSocket, generation-isolated tenancy. No CDC, no polling.

Storage

File upload and download with bucket ACLs. Public and private access control. No S3 dependency required.

Studio Dashboard

Table editor, SQL editor, auth manager, and realtime monitor. All in a browser-based admin panel.

CLI

Project scaffolding, dev server, migrations, type generation, and deployment. One tool for the full lifecycle.

Edge Functions

One endpoint, five runtimes: embedded JS (goja), PL/v8, PL/Python, a Deno sidecar, or a per-function HTTP container in any language. Pick per function.

Auto-HTTPS & static hosting

Automatic Let's Encrypt certificates (ACME), provisioned and renewed for your domains. Serve your SPA and assets straight from the proxy, gzip-compressed. No nginx, no certbot.

Job queue & cron

Durable background jobs and scheduled tasks with no Redis or RabbitMQ. Jobs are rows. Failures retry. Observability is a SELECT.

Radically simple infrastructure

No orchestrator. No message broker. No cache layer. Just PostgreSQL doing what it does best — and the proxy ships as two co-equal builds, Go or Rust, hardened to parity.

Your App ---> pgstack-proxy ---> PostgreSQL REST, Auth, + pg_reactive WebSocket extension
Typical BaaS
15+ containers
pgStack
2 processes

Up and running in 60 seconds

From zero to a full backend with auth, REST, and live queries.

1

Scaffold your project

Initialize a new pgStack project with all configuration files and a default migration.

npx pgstack init myapp
2

Start the dev server

Launches PostgreSQL with pg_reactive and the proxy server. Hot-reloads on migration changes.

cd myapp && pgstack dev
3

Build your app

Use the TypeScript SDK, REST API, or raw SQL. Add auth, live queries, and storage as needed.

import { createClient } from '@pgstack/sdk'

Live examples

Interactive demos showing real-time SQL subscriptions, from simple filters to full-stack applications.

Example 01
Live Product Catalog

Live-updating product catalog — the simplest end-to-end demo.

Basic
Example 02
Order Feed

Streaming order feed with live status transitions.

Basic
Example 03
Revenue Dashboard

Live GROUP BY aggregate with rolling charts that recompute on every write.

Intermediate
Example 04
Category Leaderboard

Window functions in a live query — ranks shifting as the data lands.

Intermediate
Example 05
Real-Time CRM

Customer activity stream with row-level filtering and per-row badges.

Intermediate
Example 06
Inventory Monitor

Low-stock alerts and threshold tripwires triggered from the live subscription.

Intermediate
Example 07
Multi-Filter Dashboard

Several independent live queries sharing one WebSocket connection.

Intermediate
Example 08
Order Analytics

Composite live charts driven by joins and CTEs against the order stream.

Advanced
Example 09
Price Comparison Matrix

Live pivot — products by vendor — recomputed without a polling loop.

Advanced
Example 10
Executive Scorecard

Top-level KPIs aggregating multiple feeds into one live dashboard.

Advanced
Example 11
Notify Mode

Same data — notify vs delta side-by-side. Pick the wire for the job.

Intermediate
Example 12
Interactive Tutorial

Step-by-step walkthrough — subscribe, mutate, watch deltas arrive.

Tutorial
Full-stack App
Todo App

Complete todo application with auth, REST, and real-time sync.

Full-stack
Full-stack App
Expenses

Multi-user expense tracker with auth, REST, and a live shared ledger.

Full-stack