DDL change tracking
Unlike traditional CDC tools, pgstream captures and replicates schema changes alongside data changes. No manual intervention when tables evolve.
Open source CDC tool that replicates PostgreSQL data and schema changes to any target. Built-in anonymization for safe dev and staging environments.
Traditional CDC tools break when you ALTER a table. pgstream tracks DDL changes natively and replicates them alongside your data.
Unlike traditional CDC tools, pgstream captures and replicates schema changes alongside data changes. No manual intervention when tables evolve.
Stream changes to PostgreSQL, Elasticsearch, OpenSearch, Kafka, or webhooks. Schema-based partitioning for Kafka, custom targets via the Go library.
Transform column values during replication using greenmask, neosync, or go-masker integrations. Anonymize PII on the fly as data flows from production to dev.
Initial and on-demand PostgreSQL snapshots for bulk data loads. Useful when continuous replication is overkill or you need to bootstrap a new target.
Use as a standalone CLI tool or embed as a Go library in your own applications. Only requires PostgreSQL as a dependency — no ZooKeeper, no Kafka required.
Since v1.0, pgstream uses a custom event trigger for DDL capture. No intermediate schema state table — all DDL statements are replicated, not just a curated subset.
Out-of-the-box support for the most common targets, with a Go library for building custom ones.
Postgres-to-Postgres replication with DDL tracking. Keep staging in sync with production.
Stream changes to search indexes. Schema changes are automatically reflected.
Schema-based partitioning for event streaming. Integrate with your existing data pipeline.
Send change events to any HTTP endpoint. Build custom integrations without writing a connector.
Configure column-level transformations to anonymize sensitive data during replication. Production data flows to dev and staging with PII automatically masked — no separate pipeline needed.
| Source column | Transformer | Target output |
|---|---|---|
| alice@company.com | greenmask/email | u7k2m@example.com |
| +1-555-0123 | neosync/phone | +1-555-9847 |
| alice_smith | go-masker/username | user_x8k2p |
| 34 | greenmask/noise_int | 37 |
Available as a Go binary or Docker image. Single dependency: a PostgreSQL source database.
Point pgstream at your source Postgres and choose a target: another Postgres instance, Elasticsearch, Kafka, or webhooks.
Configure column-level anonymization rules. Mask emails, hash phone numbers, randomize ages — all while maintaining referential integrity.
pgstream begins replicating data and schema changes in real time. DDL changes flow downstream automatically.
1,000+ GitHub stars
Apache 2.0 license
Go binary + library
Postgres-only dependency