# WordPress backups: what to back up and test a restore

URL: https://wp24x7.com/wordpress-backups-what-to-back-up-and-test-a-restore/
Updated: 2026-11-29
Type: blog post

> A WordPress backup only counts if you can restore it. Back up the database and the wp-content folder, plus wp-config.php, keep copies off the server and rehearse a restore on a copy before you ever need one. This guide covers what to include, where to store backups, how often to run them, a nine-step restore test and what commonly goes wrong.

## Key facts

- For: owners and administrators of WordPress sites
- Minimum: database, wp-content folder and wp-config.php
- Storage: at least one copy off the server, with its own login
- Frequency: weekly or daily for brochure sites; frequent database backups for stores
- Test: restore on a copy, block email and payments, time it
- Repeat: every quarter and after changing host or tool
- Help: backup and restore service

A backup only counts if you can restore it. **Back up the database and the `wp-content` folder, keep copies off the server, and rehearse a restore before you ever need one.**

> **Untested means unknown**
A backup you have never restored is a hope, not a plan. Time a restore on a copy this month.

## What does a WordPress site consist of?

Two things carry your site:

| Part | What it holds |
|:--|:--|
| The database | Posts, pages, settings, users, comments, WooCommerce orders, and the configuration of most plugins |
| The files | The `wp-content` folder (themes, plugins, uploads, some plugin data), `wp-config.php` in the root, any custom `.htaccess` or server config, and WordPress core, which can be reinstalled |

_Database and files, taken close together in time_

A "files only" backup misses your content. A "database only" backup misses your media and custom code. You need both, taken close together in time.

## What else is worth backing up?

- **`wp-config.php`**, which holds database credentials and keys. Store it securely, since it contains secrets.
- **Server-level settings** your host does not manage for you: cron jobs, custom PHP settings, and rewrite rules.
- **DNS records**, as a text copy.
- **Plugin licence keys** and your list of installed plugins and versions.
- **Anything outside WordPress** that the site depends on: a separate mail service, a CRM, or a payment account configuration.
- **Staging or development copies** only if they hold work not elsewhere.

## Where should backups be stored?

Follow a simple rule: keep at least one copy somewhere that an attack or failure on your server cannot reach.

- **Not only on the same server.** If the server is hacked, deleted or fails, backups stored there go with it.
- **In another provider's storage**, such as cloud object storage or a separate backup service, with its own login.
- **With restricted access.** Backup archives contain user data and `wp-config.php`. Protect them with strong credentials and, where offered, encryption.
- **With a retention period** that lets you go back before a problem began. A hack found three weeks later is not helped by a three-day history.

A host's built-in backups are useful, but check whether you can download them and how long they are kept, and treat an independent copy as a second line.

## How often should I back up?

Match the frequency to how much you could stand to lose.

| Site type | Suggested frequency |
|:--|:--|
| Brochure site that changes monthly | Daily or weekly is usually enough |
| Blog or news site | Daily |
| Store, membership site or forum | Frequent or real-time database backups; plan to reconcile orders placed since the backup with your payment provider's records |

Take an extra backup immediately before updates, migrations and any big change.

## How do I test a restore?

Do this on a copy, never on the live site.

1. **Pick a backup**, and note which date and files it contains.
2. **Create a safe destination**: a staging site from your host, a local environment, or a spare subdomain that is blocked from search engines.
3. **Restore the files and the database** with your backup tool's restore option, or by hand: upload the files, import the database, and edit `wp-config.php` for the new database.
4. **Fix the site address** if the URL differs. A search-and-replace tool that understands serialized data (for example WP-CLI's `search-replace`) should be used, not a plain text replace, since that can break settings.
5. **Block the copy from search engines and from sending email or processing payments.** A restored store that charges customers or sends order emails is a real hazard.
6. **Check it works:** log in, load the home page, open several posts, check images, test a form, and for a store check products and a test order flow in test mode.
7. **Check that the data is complete**: the latest post, the latest order, the media library.
8. **Time it.** Note how long the restore took and what went wrong. That is your recovery time, and it is better to learn it now.
9. **Write the steps down**, with who does what, so anyone can follow them under pressure.

Repeat this test every quarter and after changing hosts or backup tools.

## What commonly goes wrong?

| Problem | Note |
|:--|:--|
| Backups silently failing | Low disk space, a time-out or an expired storage key; check the job's report |
| Partial backups | Large uploads folders skipped because of a size limit |
| Database too big | Beyond the restore tool's limits; use command-line imports |
| Plugin data missing | A plugin stores files outside `wp-content` |
| Restoring over a newer site | Loses work done since the backup |
| Backup includes the infection | See [what to do in the first hour after a hack](/what-to-do-in-the-first-hour-after-a-wordpress-hack) |

## What does a good setup look like?

An automatic schedule, an off-site copy with sensible retention, an alert if a backup fails, a pre-update snapshot, and a restore test on the calendar. Our [backup and restore service](/wordpress-backup-and-restore) sets this up and proves it, our [maintenance service](/wordpress-maintenance-service) runs it, and if you need a restore now, [emergency support](/wordpress-emergency-support) can help.

- **Backup and restore** We set it up and prove it. [Read more](/wordpress-backup-and-restore)
- **Maintenance service** Runs it for you. [Read more](/wordpress-maintenance-service)
- **Emergency support** If you need a restore now. [Read more](/wordpress-emergency-support)

**Not sure your backups would restore?**
A person can test one with you.
[Free site check](/site-check)
[Post a project](/post-project)

## Frequently asked questions

### What is the minimum I must back up?

The database and the wp-content folder, plus wp-config.php. Core files can be reinstalled, but keeping the full site makes restores simpler.

### Is my host's backup enough?

It may help, but check how long it is kept, whether you can download it, and whether it sits on the same infrastructure as the site. Keep an independent copy as well.

### How often should a WooCommerce store back up?

More often than a brochure site, because orders change the database constantly. Ask about real-time or frequent database backups, and test how restoring would affect new orders.

### Why are both files and database needed?

A files-only backup misses your content, and a database-only backup misses your media and custom code. You need both, taken close together in time.

### Where should backups be stored?

Keep at least one copy somewhere an attack or failure on your server cannot reach, such as another provider's storage with its own login, protected by strong credentials and, where offered, encryption.

### How long should backups be kept?

Long enough to go back before a problem began. A hack found three weeks later is not helped by a three-day history. Check how long your host keeps its own backups and whether you can download them.

### Why is wp-config.php sensitive?

It holds database credentials and keys. Back it up, but store it securely because the archive then contains secrets.

### Why must I block a restored copy from email and payments?

A restored store that charges customers or sends order emails is a real hazard. Block the copy from search engines and from sending email or processing payments before testing.

### How do I fix the site address on a restored copy?

Use a search-and-replace tool that understands serialized data, such as WP-CLI search-replace, not a plain text replace, which can break settings.

### What commonly goes wrong with backups?

Silent failures from low disk space, time-outs or an expired storage key, partial backups from size limits, databases too big for the restore tool, plugin data stored outside wp-content and restoring over a newer site.

### What does a restore mean for a busy store?

You may lose orders placed since the backup, so you need a plan to reconcile them with your payment provider's records. Ask about real-time or frequent database backups.

### Can a backup contain the infection?

Yes, if the hack happened before the backup. Check when the infection began before restoring, and see the first-hour guide after a hack.

### What does a good setup look like?

An automatic schedule, an off-site copy with sensible retention, an alert if a backup fails, a pre-update snapshot and a restore test on the calendar.
