pgferry
CI-tested sources
MySQL 5.7, 8.0, LTS, and InnovationMariaDB 10.6 and latestSQLiteMSSQL 2017, 2019, 2022, and 2025Real migrations, no surprises
Introspects your source schema, creates matching PostgreSQL tables, and streams data, then adds keys, indexes, foreign keys, sequences, and triggers after the load.
For most migrations, that covers the entire pipeline end to end. When something can’t be migrated automatically, views, routines, generated-column expressions, or unsupported index types, pgferry plan tells you before any data is touched.
Two valid approaches, both easy
Section titled “Two valid approaches, both easy”Both are a single config file. Fast is great for dev iterations and works fine for production when you can afford to re-run from scratch. Safe adds crash recovery and validation for when you cannot.
Fast
schema = "app"on_schema_exists = "recreate"
[source]type = "mysql"dsn = "root:root@tcp(127.0.0.1:3306)/source_db"
[target]dsn = "postgres://…/target_db?sslmode=disable"Drops the target schema, skips WAL logging, and optimizes for speed. Ideal for disposable dev or staging targets you rebuild often.
Safe
schema = "app"on_schema_exists = "error"unlogged_tables = falseresume = truevalidation = "row_count"
[source]type = "mysql"dsn = "root:root@tcp(127.0.0.1:3306)/source_db"
[target]dsn = "postgres://…/target_db?sslmode=disable"Refuses to overwrite existing schemas, keeps WAL logging for crash safety, checkpoints progress, and validates row counts after the load.
How pgferry compares
Section titled “How pgferry compares”Every tool makes different trade-offs. Here’s how pgferry stacks up against the alternatives you’re most likely evaluating.
| pgferry | pgloader | AWS DMS | |
|---|---|---|---|
| Install | ✅ Single binary | ⚠️ Lisp toolchain or Docker | ☁️ Managed AWS service |
| Config format | TOML | Custom Lisp-inspired DSL | JSON + AWS Console |
| MySQL source | ✅ | ✅ | ✅ |
| MariaDB source | ✅ | ⚠️ Via MySQL source path | ✅ |
| SQLite source | ✅ | ✅ | ❌ |
| MSSQL source | ✅ | ✅ | ✅ |
| Preflight plan | ✅ Reports issues before data is touched | ❌ | ✅ Premigration assessment |
| Resumable loads | ✅ Checkpoint-based chunking | ❌ | ✅ Checkpoint-based |
| Hook phases | ✅ 4 phases | ⚠️ 2 phases | ❌ External orchestration |
| Post-load validation | ✅ Row counts + sampled hash | ❌ | ✅ Row-level comparison |
| Self-hosted | ✅ | ✅ | ❌ AWS only |
| Cost | ✅ Free and open source | ✅ Free and open source | 💰 Per replication instance hour |
pgloader has migrated a lot of databases over the years, but its own source matrix still calls out MySQL rather than MariaDB as a separate source category. AWS DMS explicitly documents MariaDB as a MySQL-compatible source. pgferry treats MariaDB as a first-class source type with its own config validation, examples, and docs.