Skip to content
masterclass Buddy

PostgreSQL · Concept

Streaming replication

PostgreSQL streaming replication uses a special startup parameter and simple-query commands to send physical WAL or logical changes. Physical mode streams WAL; logical mode streams decoded transactions through an output plugin.

Last updated

Syntax

Startup parameter: replication = true | on | yes | 1 | database
Logical start: START_REPLICATION SLOT slot_name LOGICAL
Physical start: START_REPLICATION [SLOT slot_name] PHYSICAL

In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.

Subscribe
  • IDENTIFY_SYSTEM
  • START_REPLICATION
  • CREATE_REPLICATION_SLOT
  • pg_receivewal
  • pg_recvlogical
  • pg_stat_replication
  • pg_replication_slots
  • pg_stat_wal_receiver

Source: 54.4. Streaming Replication Protocol. Checked 2026-11-03.