cloudparts

PostgreSQL

The open-source relational database that most new projects start on, extensible enough to grow into many niches.

Type
Open source
Made by
PostgreSQL Global Development Group
License
PostgreSQL License
Facts checked
5 October 2026

What it is

PostgreSQL is a client-server SQL database. A supervisor process called the postmaster listens for connections and starts one operating-system process for each client. Concurrency comes from MVCC: an UPDATE writes a new version of the row instead of overwriting it, so each query sees a consistent snapshot, and reads never block writes. The cost is that old row versions pile up until VACUUM, usually run by the autovacuum daemon, reclaims them.

What sets it apart is how much it lets you add. Extensions plug new data types, index types and functions into the server, so PostGIS adds geospatial queries, pgvector adds vector search and TimescaleDB adds time-series storage, all with the same SQL and transactions. Built in, it has jsonb documents with GIN indexes, full-text search, window functions and serializable transactions. A new major version ships about once a year and gets five years of fixes.

Why teams pick it

  • Strict, standards-minded SQL with ACID transactions up to serializable isolation
  • Extensions such as PostGIS, pgvector and TimescaleDB turn one database into many
  • jsonb with GIN indexes covers many document-store use cases
  • Permissive BSD-style licence, and every major cloud offers it as a managed service

Watch out for

  • One process per connection: thousands of clients need a pooler such as PgBouncer
  • MVCC leaves dead rows behind; autovacuum must keep up, or tables bloat and transaction IDs near wraparound
  • Writes scale up on one primary; scaling them out needs sharding through extensions or other systems
  • Major-version upgrades need pg_upgrade, a dump and restore, or replication to a new server, not just new binaries

Good for

Data model
Relational, with jsonb, arrays and types added by extensions
Query language
SQL (PostgreSQL dialect)
Client protocol
PostgreSQL wire protocol
Secondary indexes
Several index types, including GIN; extensions add more
Transactions
ACID, within one server
Default isolation
Read committed; repeatable read and serializable (SSI) on request
How it scales
Writes on one primary; read replicas; sharding through extensions such as Citus
Replication
Streaming (physical) and logical replication
Storage engine
Heap tables holding MVCC row versions, cleaned up by VACUUM
Ways to run it
Self-hosted; Amazon RDS, Google Cloud SQL, Azure Database for PostgreSQL and others

The PostgreSQL family

2 technologies built from or on PostgreSQL

Alternatives

What all relational databases have in common →Compare side by side →
MySQLOpen sourceThe long-standing open-source SQL database behind much of the web, built on the InnoDB engine.+1 MariaDBYugabyteDBOpen sourceAlso good for serializable transactions across keysA distributed SQL database that runs PostgreSQL’s own query layer on top of DocDB, a sharded, Raft-replicated storage engine built on RocksDB.CockroachDBCommercialAlso good for serializable transactions across keysA distributed SQL database that speaks the PostgreSQL wire protocol, replicates every slice of data with Raft and keeps transactions serializable across nodes and regions.NeonCommercialServerless Postgres that keeps data in a shared storage layer, so compute can scale to zero and a branch of the database is a pointer, not a copy.CedarDBCommercialA PostgreSQL-compatible database rebuilt from scratch at TU Munich, running transactions and analytics on one copy of the data on a single server.DoltOpen sourceA MySQL-compatible SQL database with Git’s model built in: every table can be branched, diffed, merged, pushed and pulled, and every commit keeps the whole database as it was.MariaDBOpen sourceThe open-source fork of MySQL started by MySQL’s original developers in 2009: the same protocol and most of the same SQL, with its own storage engines, built-in Galera clustering and features MySQL lacks.CitusOpen sourceA PostgreSQL extension that shards tables across a cluster of ordinary Postgres servers, sending each query to the one shard it needs or to all shards in parallel.OmnigresDormantOpen sourceA set of more than 30 Postgres extensions that turn one Postgres instance into an application server: it answers HTTP, runs Python, loads code from files and sends email, all inside the database’s transactions.ScramDBCommercialA brand-new, closed-source database that speaks the PostgreSQL protocol and promises transactions, analytics and vector search on one copy of the data; first builds shipped in summer 2026.XataCommercialA platform that runs unmodified Postgres on Kubernetes with copy-on-write branches at the storage layer, scale to zero, and anonymized copies of production for development.TigerBeetleOpen sourceAlso good for serializable transactions across keysA replicated database with one fixed schema, double-entry accounts and transfers, built in Zig to record money movements at high rates with strict serializability.Hyperledger FabricOpen sourceA permissioned ledger for a group of known organisations: each runs its own peers, smart contracts are written in Go, Java or JavaScript, and an ordering service puts transactions in one agreed order, with no cryptocurrency.

How it fits with other technologies

What uses PostgreSQL

Relational columns and an indexed JSON document in one table · sql

CREATE TABLE orders (
  id          bigint GENERATED ALWAYS AS IDENTITY PRIMARY KEY,
  customer_id bigint NOT NULL,
  details     jsonb NOT NULL,
  created_at  timestamptz NOT NULL DEFAULT now()
);
CREATE INDEX orders_details_idx ON orders USING gin (details jsonb_path_ops);

-- the containment operator @> can use the GIN index
SELECT id, customer_id, details->>'carrier' AS carrier
FROM orders
WHERE details @> '{"status": "shipped"}'
  AND created_at > now() - interval '7 days';

See it in a real stack

Small lakehouse on DuckLake →
Live model
What you’re watchingA nightly load writes new rows: DuckLake commits the snapshot to PostgreSQL and the data to S3 as Parquet. Analysts’ queries look up the current files in the catalog and read them from S3.

Worth exploring

Article· June 2026Durable Queue Workers With Just PostgresFatih Yildiz (mfyz)Starts with the FOR UPDATE SKIP LOCKED queue, then shows what to add when a job has several steps: Absurd stores each step’s result in Postgres, so a crashed worker resumes from the last checkpoint. The author calls it a fit for small and medium projects, not high volume.
Article· June 2026Making Postgres Queues ScaleQian Li and Peter Kraft, DBOSHow DBOS got its Postgres-backed queues to 30,000 workflows a second: SKIP LOCKED, the weaker READ COMMITTED isolation unless a queue needs global limits, partial indexes on waiting rows only, and an index that matches the dequeue order. DBOS wrote it about its own product, but the techniques apply to any Postgres queue.
Article· April 2026Keeping a Postgres queue healthySimeon Griggs, PlanetScaleWhy a busy queue table fills with dead rows, and how one long query elsewhere can stop vacuum from cleaning them up and slow every dequeue. The diagnosis applies to any Postgres; the fix it ends on, Traffic Control, exists only on PlanetScale.
Slides· September 2025How and Why Datadog moved from cloud-managed to self-managed PostgresNick Canzoneri, Datadog, at PGConf NYC 2025Slides from a talk on why a company running hundreds of Postgres clusters across several clouds left managed services for its own Postgres platform on Kubernetes, how it moved a whole region, and what got better and worse. The stack is Patroni (with ZooKeeper for leader election), WAL-G backups, a Helm chart rather than an operator, and Temporal workflows for automation. Useful before you weigh RDS-style convenience against running Postgres yourself.
Video· April 2022Queues in PostgreSQLThomas Munro, PostgreSQL committer, at Citus Con 2022A Postgres developer walks through what queue-like workloads do inside the database, and the complications of using Postgres as a job or message queue.
All resources →

Benchmarks

Benchmark · ClickHouse Inc.ClickBenchHow fast analytical databases run 43 SQL queries over one 100-million-row table of web analytics events, on the same cloud machines.Includes PostgreSQL · 7 caveats to read first
How to read a benchmark →
Where it came from1986–2025

By the mid-1980s, relational databases handled business records well, but engineering work such as CAD, geographic data and graphics needed things like polygons and lines that the systems couldn’t store efficiently. Michael Stonebraker had led the Ingres project at UC Berkeley, but its code had been “hacked up enough” that adding major new features was extremely difficult. So in 1986 he and Lawrence Rowe designed a successor, POSTGRES (“post-Ingres”), whose goals included letting users add their own data types, operators and access methods. Implementation began that year, funded by DARPA, the Army Research Office, the NSF and ESL, Inc.

Berkeley released versions 1 to 4.2 from 1989, all using the project’s own query language, PostQUEL. As the research wound down, students Andrew Yu and Jolly Chen swapped PostQUEL for SQL in 1994 and released the result as Postgres95. Volunteers outside Berkeley adopted the code, renamed it PostgreSQL in 1996 and released version 6.0 in January 1997. They have run it ever since as the PostgreSQL Global Development Group.

A permissive licence and an extensible core made it a common starting point for commercial databases and for extensions such as PostGIS. In 2010 Heroku made it the default database on its platform, which helped frameworks such as Ruby on Rails and Django recommend it too.

Why it’s built this way

Users can add types, operators and index methods
Engineering data could be faked with plain tables, but the 1986 design paper called the resulting performance unacceptable. Making the type system and access methods pluggable is why PostGIS, pgvector and TimescaleDB can exist as extensions.
One operating-system process per connection
The designers knew a single server process would perform better, but it meant writing what amounted to a special-purpose operating system. With a small team, they chose the simpler process-per-user model on Unix, which is why PostgreSQL still needs a pooler for thousands of clients.
Write new row versions instead of overwriting
POSTGRES kept every record as a chain of versions stamped with transaction IDs, which simplified crash recovery and allowed “as of” queries. PostgreSQL later added a write-ahead log and dropped time travel, but kept the versions for MVCC, and with them the need for VACUUM.

Timeline

  1. 1986

    POSTGRES project begins at UC Berkeley under Michael Stonebraker

  2. 1989

    Version 1 released to outside users

  3. 1994

    Andrew Yu and Jolly Chen add SQL, creating Postgres95

  4. 1996

    Renamed PostgreSQL; version 6.0 follows in January 1997

  5. 2010

    9.0 adds built-in streaming replication and hot standby

  6. 2014

    9.4 adds jsonb with GIN indexing

  7. 2025

    PostgreSQL 18 adds asynchronous I/O

Sources20 · facts checked 5 October 2026

Improve this page on GitHub