Restore WordPress from backup safely
Restore WordPress files and database carefully after a failed update, bad migration, broken plugin, or damaged wp-config.php change.
When to use this guide
Use this when a rollback is not enough and the fastest safe path is restoring a known-good WordPress file and database backup.
Safety notes
- Take a fresh snapshot of the broken state before restoring.
- Confirm backup time, site URL, database name, table prefix, and file root.
- Avoid restoring the database over newer orders, form submissions, or user records without a business decision.
- Keep the old
wp-config.phpavailable for comparison and redaction.
Basic steps
- Identify whether you need files only, database only, or both.
- Confirm the backup predates the first known failure.
- Restore in the hosting panel, backup tool, or deployment system that owns the site.
- Compare
wp-config.phpdatabase settings and$table_prefixafter restore. - Clear only the affected caches and test public pages plus
wp-admin.
Expected result
The site should return to the known-good version without mixing files from one version with a database from another incompatible version.
Next links
- If a smaller rollback is possible, use Roll back a website change safely.
- If the restored site cannot connect to the database, use Repair WordPress database settings in wp-config.php.
- If restored files cannot run, use Check WordPress file permissions.
Review notes
- Last reviewed
- 2026-05-05
- Reviewed by
- FaultForge Editorial Team, Web operations reviewer
- Tested on
Current stable browser behavior, server log workflows, WordPress administration, nginx proxy behavior, and MySQL/MariaDB operational checks.