WordPress Backup and Restore: How to Back Up Your Site, Store Copies Safely and Restore It When Something Breaks
How to back up and restore WordPress: what to include, how often, the 3-2-1 rule, UpdraftPlus and host backups, and restoring by plugin or by hand.

On this page
- What a WordPress backup must include
- The 3-2-1 rule, applied to websites
- How often to back up, and how long to keep copies
- Your backup options
- Setting up automatic backups with UpdraftPlus
- How to restore a WordPress backup
- Restoring a WooCommerce store without losing orders
- Test your backups
- Backup mistakes to avoid
- Quick check
- When to get help
- FAQs
- A complete WordPress backup has two parts, the files (mainly wp-content and wp-config.php) and the database, and you need both to restore a working site.
- Follow the 3-2-1 rule: host backups plus an automatic plugin or service backup stored off the server, such as UpdraftPlus to Google Drive, BlogVault or Jetpack VaultPress Backup.
- Restore through your backup tool or hosting panel, or manually with File Manager and phpMyAdmin, and test a restore on staging every few months so you know it works.
To back up WordPress properly, save both parts of the site, the files and the database, on an automatic schedule, and keep at least one copy somewhere other than your hosting server. In practice that means your host's backups plus a plugin or service such as UpdraftPlus, BlogVault or Jetpack VaultPress Backup sending copies off-site. To restore, use the same tool or your hosting panel, or restore the files and import the database by hand if the dashboard won't load. Then test a restore every few months, because an untested backup is only a hope.
Below is what a backup needs to contain, how often to take one, the main options, and step-by-step restores by plugin, by hosting panel and manually. Regular off-site backups are the first thing my WordPress maintenance plans set up, but everything here works if you're doing it yourself.
What a WordPress backup must include
| Part | What it holds | Where it lives |
|---|---|---|
| Database | Pages, posts, products, orders, customers, users, menus, widget and plugin settings | MySQL or MariaDB on your host |
| wp-content folder | Your theme, plugins and the uploads folder (images, PDFs, other media) | public_html/wp-content, or wherever WordPress is installed |
| wp-config.php | Database details, security keys and custom settings | The main WordPress folder |
| .htaccess and other root files | Redirects, rewrite rules, server tweaks, verification files | The main WordPress folder |
WordPress core files can be downloaded again at any time, so most backup plugins skip them. What you can't replace is the database and wp-content. A files-only backup loses your content and settings; a database-only backup loses your images, theme and plugins.
The 3-2-1 rule, applied to websites
The 3-2-1 rule comes from general IT practice: keep three copies of your data, on two different kinds of storage, with one copy off-site. For a WordPress site, that usually looks like this:
- The live site itself, plus your host's automatic backups.
- A plugin or service backup stored outside your hosting account: Google Drive, Dropbox, Amazon S3 or the service's own servers.
- An occasional downloaded copy kept in a separate account you control, especially before big changes.
The off-site copy is the one that matters most. If your hosting account is suspended, hacked, deleted over an unpaid bill or lost to a server failure, backups stored in that same account can go with it.
How often to back up, and how long to keep copies
| Type of site | Backup frequency | Keep copies for |
|---|---|---|
| Brochure site that rarely changes | Weekly, plus before every update | At least a month |
| Business site with a regular blog | Daily | 2 to 4 weeks |
| WooCommerce store or booking site | Daily at minimum; more often, or real-time, for busy stores | About a month |
| Any site, before updates, redesigns or migrations | A fresh manual backup | Until the change is confirmed working |
Retention matters as much as frequency. Hacks and broken content are often noticed days or weeks later, and if you only keep the last three nightly backups, all three may contain the problem. The backup before an update is the one you'll reach for most often; how to update WordPress safely shows where it fits.
Your backup options
- Host backups. Most hosts take automatic backups; Hostinger shows them in hPanel and many Indian cPanel hosts use JetBackup. They're convenient for quick restores, but check how often they run and how long they're kept on your plan, and remember they live with the host.
- UpdraftPlus. The free version schedules file and database backups, sends them to Google Drive, Dropbox and other storage, and restores from the dashboard. Paid add-ons add things like incremental backups and migration.
- BlogVault. A paid service that stores backups on its own servers, backs up incrementally to reduce server load, and can restore a site even when it won't load.
- Jetpack VaultPress Backup. Automattic's paid backup service, with real-time backups on some plans and restores from your WordPress.com account.
- Duplicator or All-in-One WP Migration. Better suited to making a one-off archive or moving a site than to daily scheduled backups.
Features and pricing change, so check the current plans at the time you choose. If you're weighing BlogVault against Jetpack, or either against UpdraftPlus, WordPress backup plugins compared goes through the trade-offs in detail.
Setting up automatic backups with UpdraftPlus
- Install and activate UpdraftPlus from Plugins > Add New.
- Go to Settings > UpdraftPlus Backups and open the Settings tab.
- Set a schedule for files and one for the database, and how many copies of each to keep. On a store, the database can run more often than the files.
- Choose remote storage, such as Google Drive, and follow the steps to connect it. Use a Google account the business owns, not a personal one that might leave with an employee.
- Exclude cache folders and other backup plugins' folders, so you're not backing up backups.
- Save, then click "Backup Now" and confirm the files actually appear in your Google Drive.
If scheduled backups don't run on time, the cause is often WordPress's built-in scheduler, which only fires when someone visits the site; see WP-Cron explained.
How to restore a WordPress backup
Before you restore
- Pick the right backup: the latest one taken before the problem started, not simply the newest.
- Back up the broken site first. If the restore goes wrong, or you need something from the current version later, you still have it.
- On a store, note the time of the backup. Orders, customers and stock changes since then aren't in it (see below).
- After a hack, don't just restore. The backup still contains whatever weakness let the attacker in, and may contain the malware itself if it was taken after the infection; see removing WordPress malware step by step.
Restore with your backup plugin
In UpdraftPlus, open the Existing Backups list, click Restore next to the backup you want, and choose which parts to restore: database, plugins, themes, uploads or others. Restoring only the part that broke, such as plugins after a bad update, is faster and leaves the rest of the site untouched. Services like BlogVault and Jetpack restore from their own dashboards, which helps when WordPress itself won't load.
Restore from your hosting panel
Host restores are often the quickest route when you can't get into WordPress. In hPanel or a cPanel tool such as JetBackup, pick the date and choose files, database or both. Some hosts restore the whole account, including email, so read the options before you click.
Restore manually
If neither of those works, you can restore by hand with File Manager or SFTP and phpMyAdmin:
- Upload the backed-up wp-content folder and wp-config.php, replacing the broken versions.
- In phpMyAdmin, select the site's database, drop or empty the existing tables, then use the Import tab to upload the .sql file from your backup.
- Check that the database name, user, password and table prefix in wp-config.php match the database you imported into.
- If the domain or folder has changed, update the site URLs with a proper search-replace tool rather than editing the database by hand.
Large databases can exceed phpMyAdmin's upload limit. With SSH access, WP-CLI handles exports and imports of any size:
wp db export before-restore.sql
wp db import backup-2026-10-01.sql
wp cache flush
After restoring
Re-save permalinks in Settings > Permalinks, clear every cache, then check key pages on a phone, submit each form, log in and, on a store, place a test order. If the site was hacked, change all passwords as well.
Restoring a WooCommerce store without losing orders
A full restore puts the database back to the moment of the backup, so every order, customer account and stock change since then disappears. On a busy store, that's a real loss. Safer options, in order:
- Roll back the single plugin or theme that caused the problem, or restore only the files.
- If the database must be restored, put the shop into maintenance mode first, export recent orders, and re-enter them afterwards.
- Restore to a staging copy, check it, and move only what's needed to the live store.
This is why stores benefit from more frequent backups and from testing updates on a staging site before they reach customers.
Test your backups
Backups fail quietly: storage fills up, a cloud connection expires, or a schedule stops running after a plugin update. Every quarter, restore a recent backup to a staging site or a spare subdomain and check that pages, images, forms and logins work. While you're there, confirm the backup files are a sensible size; a backup that's suddenly much smaller than usual is a warning sign.
Restoring an infected backup only brings the problem back. Learn how to tell if your WordPress site has been hacked before choosing which copy to restore.
Backup mistakes to avoid
- Keeping every copy on the same server as the site
- Backing up the database but not the uploads folder, or the other way round
- Never testing a restore
- Leaving backup archives in a public folder, where anyone who guesses the file name can download your database
- Letting the Google Drive or Dropbox account fill up, so new backups silently fail
- Storing backups in an account that belongs to a former developer or employee
Backups are one part of being ready for a bad day; a simple website disaster recovery plan covers logins, contacts and who does what.
Quick check
A backup you have never restored is only a hope. Once a quarter, restore your latest backup to a staging site or a subdomain and click through the homepage, a form and (for stores) the checkout. To check that the database can be exported cleanly, run this with WP-CLI and confirm the file is not empty:
wp db export backup-test.sql
ls -lh backup-test.sql
When to get help
If a restore has failed, your backups are stored only on the same hosting account, or you're not sure what your backup plugin actually saves, get it checked before you need it. Off-site backups kept separate from your hosting are part of WordPress maintenance plans. Send the details through the contact form for a fixed quote.
Related fixes: WordPress admin bar or dashboard missing and WordPress revisions not showing.
For a click-by-click setup of one plugin, see backing up WordPress with UpdraftPlus.
FAQs
Are my hosting company's backups enough?
They're a good first layer, but not enough on their own. They're stored with the host, so a suspended or compromised account can take them too, and retention on cheaper plans can be short. Add an off-site backup you control.
How often should I back up my WordPress site?
Weekly for a site that rarely changes, daily for an active business site, and daily or more often for a store, plus a fresh backup before every update. Keep copies for a few weeks, not just a few days.
Can I restore a backup if I can't log in to WordPress?
Yes. Restore from your hosting panel, from a service like BlogVault or Jetpack that works outside WordPress, or manually by uploading the files and importing the database in phpMyAdmin.
Should I restore a backup after my site is hacked?
Only as part of a cleanup. A backup from before the hack removes the malware, but not the outdated plugin or stolen password that let it in, so the site can be reinfected within days.
Does a backup include my emails?
Usually not. WordPress backups cover the website's files and database. Email hosted with your web host, Google Workspace or Zoho is stored separately and needs its own backup arrangement.
Need help with your website?
I'm a freelance WordPress developer building fast, SEO-friendly websites since 2020. Tell me what you need and I'll reply with a plan and a fixed quote, usually within 24 hours.


