How long does it take to restore a Postgres database from a dump? The restore step took about 20 seconds to 12 minutes in this Postgres restore time benchmark. The four databases ranged from a 400 MB Supabase project to a synthetic 10 GB database with 18.8 million rows. Each was restored into a fresh PostgreSQL 17 database on the same 2 vCPU / 8 GB VM.
Some numbers from it:
- The restore step averaged 722 seconds (about 12 minutes) for the 10 GB database and 69 seconds for the 1 GB database, over two drills per size.
- 77% of the 10 GB restore (559 seconds) went to building indexes, constraints and foreign keys. Loading the 18.8 million rows took 163 seconds.
- In a separate single-job
pg_restorerun of the 10 GB dump, the slowest step was building a pgvector HNSW index over 200,000 384-dimensional embeddings (185 seconds). Loading the largest table, with 13.5 million rows, took 141 seconds. - The compressed custom-format dumps were 17–22% of the database size. The 10 GB database produced a 1.74 GiB dump.
- Across the four sizes, all 27 drills passed. That count includes runs with BackupDrill CLI 2.2.5 and 2.3.0.
The test database ran with fsync, synchronous_commit and full_page_writes off. With fsync off, a crash can corrupt the restored copy. The benchmark lists the full settings so you can compare them with your own restore target.
If you're estimating a recovery window, time the row load and the index builds separately. Dump size alone won't tell you how long the indexes will take to rebuild.
The drills used the open-source BackupDrill CLI (MIT) to restore dumps into throwaway Postgres containers. The CLI checked for missing tables and unexpectedly empty tables. For the 400 MB and 1 GB databases, the benchmark also compared exact row counts with the source. BackupDrill CLI 2.3.0 used two restore jobs. With the same dumps and PostgreSQL settings, its restore step ranged from 4% faster to 5% slower than single-job pg_restore across the four sizes.