How to restore a website from a cPanel backup

Last updated 2026-11-19

If your host runs cPanel, the quickest way back to a working site is usually one of three doors: the Backup Wizard for a guided restore of partial backups, JetBackup for one-click restores from server snapshots, or File Manager + phpMyAdmin when all you have is a zip and a .sql. Pick the door based on what kind of backup you hold, not on which one looks shortest.

If no backup can be found at all, see what the Wayback Machine kept of your site with a free scan — it shows the old design and a few sample pages.

Before you restore

Four checks first. Every one of them has saved more sites than any plugin. If no cPanel backup turns up, scan your site in the Wayback Machine before you give up on the content.

  1. Do you have both halves? A complete WordPress backup is the files (core, themes, plugins, uploads, wp-config.php, .htaccess) and a database dump, usually a .sql or .sql.gz. WordPress.org’s handbook is plain that you need both to fully restore a typical site (developer.wordpress.org, WordPress Backups).
  2. Is the backup from before the problem? A backup taken after an attacker got in will put the attacker back with it. If you are restoring because of a hack, check the backup’s date against your first “something is wrong” moment.
  3. Back up the current state first — even if it is broken. Restoring replaces what is there. If the archive turns out to be corrupt halfway through, the broken site is still better than nothing. In cPanel: Files → Backup → Download a Full Account Backup (that writes to Home, not to your machine — grab it before you touch anything).
  4. Know which cPanel tool your host enables. The three tools live in different places and do different things:

Which cPanel tool restores what

Tool Where it lives Restores files? Restores database? Typical downtime Main risk
Backup Wizard Files → Backup Wizard Home directory (partial) Yes, one DB at a time Minutes Cannot restore a full account backup from cPanel — that is WHM only
JetBackup 5 Files → JetBackup (if installed) Full account or individual files Full account or individual tables Minutes Granular restore overwrites current data in place — snapshot first
File Manager + phpMyAdmin Files → File Manager and Databases → phpMyAdmin Yes, manual upload Yes, manual SQL import 20–60 minutes Mixing character sets or table prefixes

If you are not sure which is available, open cPanel and look under Files. Backup Wizard ships with cPanel by default; JetBackup is a paid add-on your host chooses to enable (JetBackup 5 cPanel docs).

Full account restore vs partial restore

cPanel’s own documentation is blunt about one thing: cPanel cannot restore a full-account backup file from inside cPanel itself. Full-account restores happen in WHM, the server-level panel your host runs; you can request one by opening a ticket. What you can do yourself from cPanel is restore partial backups — the home directory, a database, or email forwarders/filters (cPanel Docs, Backup).

For a WordPress site, a partial restore is almost always enough: the home directory holds public_html (your WordPress files), and the database partial restores the content. If you also need mailboxes or DNS, that is where WHM or a host ticket comes in.

Restore from cPanel Backup Wizard

Use this path if you have .tar.gz or .zip partial backups from cPanel’s own Backup or Backup Wizard screen. The Wizard walks you through three steps (Backup, Restore, choose type).

1. Pick the backup type

From the cPanel home screen go to Files → Backup Wizard → Restore. You will be asked to pick one of: Home Directory, MySQL Databases, Email Forwarders, or Email Filters (cPanel Docs, Backup Wizard). For a WordPress restore you will come back to this screen twice: once for Home Directory (the files) and once for MySQL (the database).

2. Restore Home Directory

Click Home Directory, then Choose File, and pick the .tar.gz that Backup Wizard produced for the home directory. Click Upload. cPanel extracts the archive on top of your current home folder: files with the same path are overwritten; files that only exist on the live site survive. That last part matters — if you want a clean replacement, rename or empty public_html first.

3. Restore the database

Go back to Backup Wizard → Restore → MySQL Databases, upload the .sql.gz for your WordPress database, and click Upload. The Wizard imports into the database of the same name. If the target database does not exist on the account yet, create it first in Databases → MySQL Databases and add the WordPress user to it with ALL PRIVILEGES.

4. Point wp-config.php at the database

If you restored into a database that has a different name, user or password from the original, open public_html/wp-config.php in File Manager (right-click → Edit) and update DB_NAME, DB_USER, DB_PASSWORD and DB_HOST. An “Error establishing a database connection” after a restore almost always points to this file.

Restore from JetBackup

JetBackup is a per-server backup add-on many hosts install alongside cPanel. If you see JetBackup under Files, the fastest full-site restore is this one: the host already holds daily or weekly snapshots of your account, and a full restore is one click.

1. Open the backup list

Go to Files → JetBackup 5 → Full Account Backups (or File Backups for file-only snapshots). You will see a list of snapshots by date (JetBackup 5, Full Account Backups). Pick one from before the problem started, not the newest.

2. Choose what to restore

Click Restore on the snapshot row. JetBackup asks whether to restore the whole account or specific items (home directory, databases, emails). For a WordPress site that is only broken at the application layer, restoring Home Directory + the WordPress database is usually enough and keeps your mailboxes intact.

3. Confirm the overwrite

JetBackup shows a diff summary and asks you to confirm. It overwrites the live account in place. There is no undo inside JetBackup for a completed restore, so make sure the current state is captured in a separate snapshot first — either the download from step 3 of “Before you restore” above, or a JetBackup Backup Now if your host allows it.

4. Wait for the queue

JetBackup runs the restore as a queued job, so the button returns immediately and the actual restore happens over the next few minutes. The Queue tab shows progress. Do not re-click Restore; a second queued job can overwrite the first one halfway through.

Restore files only, via File Manager

Sometimes all you have is a zip someone sent you, or a download from Download a Full Account Backup that you unpacked on your laptop. cPanel File Manager can take over from there.

  1. In cPanel open Files → File Manager and go to public_html.
  2. If you want a clean replacement, select all existing files and move them to a folder called _old (or delete them after step 5 confirms the restore works).
  3. Click Upload and upload your archive (.zip, .tar, .tar.gz). File Manager supports direct upload of these formats up to the host’s limit (often 500 MB).
  4. Right-click the uploaded archive and pick Extract. Point the destination at public_html.
  5. Delete the archive once extraction is done. Leaving a public .zip of your whole site in public_html is a security hole.

Files only is only half of a WordPress restore. The database comes next.

Restore the database

You have two realistic options inside cPanel: phpMyAdmin (web UI) and WP-CLI (command line through the Terminal feature, if your host enables it).

phpMyAdmin

Open Databases → phpMyAdmin. Select the target database on the left. Open the Import tab, click Browse, pick the .sql or .sql.gz file, and click Go (phpMyAdmin Docs, Import and Export). Two gotchas from that page worth repeating: a Quick export should be imported into a database that has no tables, and if your dump is larger than the server’s upload limit (often 50 MB), phpMyAdmin will refuse — that is when WP-CLI helps.

WP-CLI (if cPanel exposes Terminal)

Open Advanced → Terminal, cd public_html, and run:

wp db import site-db.sql

WP-CLI reads wp-config.php and imports into the database already configured for the site, so you do not need to type credentials (WP-CLI Handbook, db import). If the dump is gzipped, decompress it first with gunzip site-db.sql.gz. For a different domain, follow the import with wp search-replace to rewrite the old URL to the new one, and WP-CLI warns the handbook example never to touch the GUID column (WP-CLI Handbook, search-replace).

Verify and clean up

A restore that finishes without an error is not the same as a restore that worked. Walk through these before you tell anyone the site is back.

  1. Log in at /wp-admin. If the login page redirects or 500s, the first suspect is the four DB_ lines in wp-config.php, then $table_prefix if your backup used a non-default prefix.
  2. Re-save permalinks. In Settings → Permalinks, click Save Changes once. This rewrites .htaccess rules and fixes “404 on every post” after a restore. The Permalinks screen is documented in the WordPress handbook under Settings.
  3. Visit the homepage, three posts, a page with images, and the contact form. Log out and repeat in a private window — some caching plugins serve a stale “site under maintenance” page to visitors for an hour after a restore.
  4. Purge the cache. If you run Cloudflare, LiteSpeed Cache, WP Rocket, or similar, purge everything — stale HTML from before the restore will mask fixes for hours.
  5. Re-check file permissions. After a File Manager upload, cPanel’s default of 0644 for files and 0755 for folders is correct for WordPress; a copy from Windows sometimes carries wrong flags. Right-click public_html → Permissions, apply recursively if anything looks off.
  6. Google Search Console. If the site was down for more than a few hours, submit the sitemap again and request indexing on the homepage; Googlebot otherwise keeps serving its last cached impression.

When cPanel can’t help

Three situations need something other than a cPanel restore:

  • The backup is older than the problem. If the attacker (or the hosting failure) happened before your last clean backup, restoring it brings the problem back. Clean the files instead of restoring them, or restore to a staging subdomain and audit before swapping. Our hacked website repair walkthrough covers the clean-then-restore order.
  • No backup at all. This is the common case — the site is gone and the host has nothing older than yesterday’s blank. The website recovery hub explains the three realistic paths from here (rebuild, archive restore, or accept the loss), and the recover deleted website page is the place to start when the only copy left is in the Internet Archive.
  • cPanel will not finish the restore. A broken .sql or a .tar.gz cPanel refuses to extract usually means a mid-transfer corruption. Download the archive again with a fresh link, verify the size matches the original, and only then retry. If the archive is truly corrupt, see our how to restore a WordPress website from a backup guide for the manual phpMyAdmin + SFTP path that bypasses cPanel’s own extractors.

FAQ

Can I restore a cPanel full-account backup myself?

No, not from inside cPanel. Full-account restores are a WHM feature, so the host runs them from a ticket. From cPanel you can only restore partial backups — home directory, individual databases, email forwarders, email filters (cPanel Docs, Backup).

Backup Wizard or File Manager — which should I use?

Backup Wizard is easier when the backup came out of Backup Wizard in the first place; it knows the archive format and does the home-directory + database steps separately. File Manager is better when the backup came from somewhere else (a plugin export, a developer’s zip) and you want to see each file before it lands.

My database dump is too big for phpMyAdmin — what now?

Try WP-CLI via Advanced → Terminal if your host enables it (wp db import). If Terminal is disabled, split the .sql into smaller files or raise the upload limit via a custom php.ini — cPanel’s Software → MultiPHP INI Editor can increase upload_max_filesize and post_max_size for the account.

The site is up but images are missing — did the restore fail?

Probably not. The database points to wp-content/uploads/YYYY/MM/ paths; if the restore skipped uploads, the posts load but images 404. Re-check that public_html/wp-content/uploads exists and matches the counts in the backup archive.

Do I need a staging subdomain to restore safely?

Not required, but recommended if the site is live and traffic-earning. Restore into staging.yourdomain.com or a subfolder first, verify as above, then swap. The main risk of restoring in place is that a bad dump takes the current (broken but visible) site offline entirely.

Restore a lost website →