Before you update WordPress, edit website files, or change a database, create a backup you can actually restore. A small mistake can affect your layout, disable a form, or make your site unavailable.

The key is saving the right files and databases, then understanding which restoration options your account supports. This tutorial starts with those essentials and walks through creating a backup before you make changes.

Understand What Your Website Backup Needs to Include

A working website often depends on more than the files you see in File Manager. WordPress and many other content management systems store pages, settings, and other content in a database, while themes, plugins, and uploaded images live in files.

Create your file and database backups as close together as possible. For sites that accept orders, registrations, or other submissions, consider pausing those activities during the backup or using an appropriate maintenance window.

Website files and the correct document root

Your primary domain’s files often reside in public_html, but additional domains and subdomains may use different folders. In cPanel, open Domains and check the document root for the website you plan to change.

A complete file backup should include application files, uploaded media, and hidden configuration files such as .htaccess. For WordPress, wp-config.php is especially important because it contains database connection settings and other configuration details.

Databases and recovery limitations

If your website uses WordPress, check the DB_NAME value in its wp-config.php file to identify the correct database. Avoid editing the file while checking it, and keep its contents private because it contains sensitive credentials.

Laptop displaying the cPanel dashboard with website backup tools

Also distinguish between a full account backup and a backup you can restore yourself. A full cPanel backup can include website files, databases, email, and account settings, but restoring that full archive generally requires your hosting administrator’s assistance or administrator-level tools.

Create and Verify a Backup Before Editing Your Site

Log in to cPanel through your account’s trusted access method, then look for Backup Wizard under Files. If that tool is unavailable, look for Backup.

For a typical database-driven website, save both a home directory backup and a backup of each database the site uses. A home directory backup alone is not a complete WordPress recovery plan, and a database export alone will not preserve your themes, plugins, or uploaded files.

Download the home directory and database backups

  1. Open Backup Wizard and select Back Up.
  2. Under the partial backup options, choose Home Directory and download the archive. This may include files for multiple websites in your account, not just the site you intend to edit.
  3. Return to the backup options and choose MySQL Databases, or the equivalent database option displayed in your account.
  4. Download the database identified for your website. Repeat this step if the site depends on more than one database.
  5. Keep the downloaded files together in a clearly labeled folder that identifies the website and backup date.

If you use the Backup page instead, locate the partial backup download options for the home directory and individual databases. A full account backup can provide an additional safeguard, but confirm how it would be restored before relying on it as your only recovery method.

Check that your recovery files are usable

Wait for every download to finish, then confirm that the files are present and have plausible sizes. If possible, use an archive utility to check that the home directory archive opens and contains the expected website folder and configuration files.

Store a copy outside the website account in a secure location with restricted access. Backups can contain customer information, credentials, and private business data, so do not leave them in a publicly accessible website folder.

cPanel Backup Wizard showing options for creating a website backup

Make Changes in a Way That Keeps Recovery Simple

Once your backup is verified, record what you plan to change and when you start. Update one component at a time when practical, then check the website before continuing.

For major WordPress updates, custom code changes, or database modifications, test on a staging copy first. A staging site should use a separate database, have restricted access, and avoid sending real customer emails or processing live payments.

Protect activity that happens after the backup

Restoring a database returns its content to an earlier point in time. Orders, form entries, user accounts, and content changes created after the backup may be lost.

For example, if you backed up an online store at 9 a.m. and it received orders before an update failed at noon, restoring the morning database could remove those orders from the website.

Restore Website Files Through cPanel

The right restoration method depends on what changed. If you damaged a single file, replacing that file may be enough. If an update modified application files and the database, recovering a matching backup pair is generally safer than restoring only one part.

Restore a home directory backup

  1. Pause website activity if the restoration could affect customer submissions or transactions.
  2. Download a separate copy of the current files and database before overwriting anything.
  3. Open Backup Wizard, choose Restore, and select Home Directory. Alternatively, use the home directory restore option on the Backup page.
  4. Select the compatible home directory backup archive you downloaded from cPanel, then upload it.
  5. Wait for the restoration process to finish and review any status messages or errors before proceeding.

A home directory backup may contain several websites and other account files. Restoring it can overwrite more than the website you intended to repair. It also may leave files that were created after the backup, so do not assume it produces a clean replacement of the directory.

Website backup file downloading to a folder on a computer

Do not upload a full account backup into a partial home directory restore field. These archives serve different purposes. If you have only a full account backup, ask your hosting administrator how it can be restored or whether the needed components can be recovered separately.

Recover an individual file when appropriate

If you know exactly which file caused the problem, extract the home directory archive on your computer and locate the original file. In cPanel, open File Manager, navigate to the correct document root, and save a copy of the current file before replacing it.

For example, replacing a recently edited theme file with its backed-up version may resolve a PHP error without rolling back the database. This targeted approach is not suitable when a plugin update changed database tables or when multiple related files must remain on the same software version.

Restore the Website Database Carefully

Database restoration can replace business-critical information, so confirm the database name again before starting. If the account contains multiple WordPress installations, compare the destination with the DB_NAME setting in the affected site’s wp-config.php file.

Use the matching database restore option

  1. Preserve an export of the current database and keep it separate from your recovery backup.
  2. Open Backup Wizard, select Restore, and choose MySQL Databases, or use the corresponding database restoration option on the Backup page.
  3. Select the compatible database backup downloaded through cPanel.
  4. Start the upload and wait for the restoration result. Do not assume that selecting a file means the import has completed successfully.
  5. Check that the restored database matches the connection settings used by the website.

Restoration behavior can vary with the tool, backup format, and account permissions. Confirm whether an existing database will be overwritten and whether database users and their privileges need to be reassigned.

cPanel restoration interface with a website backup file selected

Know when phpMyAdmin needs extra care

If you have a standard SQL export instead of a cPanel database backup, phpMyAdmin may offer an import route. However, importing SQL into an existing database does not always replace it cleanly.

For a clean recovery, an experienced administrator may import the backup into a separate empty database, assign an authorized database user, and update the application’s connection settings.

Large database imports may exceed browser upload or execution limits. If an import times out or produces errors, ask your administrator to complete it using an appropriate server-side method.

Check the Website After Restoration

A successful upload message is only the first check. Recovery is complete when the website loads correctly and its important functions work. Keep the site in maintenance mode, if available, until you have verified the parts that affect customers.

  • Public pages: Check the homepage, key service pages, navigation, images, and mobile layout.
  • WordPress access: Confirm that you can sign in and that expected themes and plugins are present.
  • Forms: Submit a clearly labeled test and verify both delivery and any saved entry.
  • Transactions: Use the payment provider’s approved testing process to check checkout without creating unintended charges.
  • Content: Confirm that expected posts, products, accounts, and settings match the recovery point.
  • Search visibility: Check that maintenance tools or staging settings have not left the live site blocked from indexing.

Clear relevant WordPress and content delivery network caches after the restoration, then test in a private browser window. A cached page can make a repaired website appear broken or make an incomplete recovery look successful.

Troubleshoot common recovery problems

A database connection error often points to a mismatch between the database name, username, password, or host in the application configuration. Confirm those values and the user’s database privileges without sharing credentials publicly.

Person checking a restored website in a browser window

A blank page or server error may indicate incompatible PHP settings, missing files, incorrect permissions, or a plugin conflict. Review available error logs in cPanel and avoid changing permissions broadly as a quick fix.

Missing pages or incorrect redirects can result from rewrite rules, cached redirects, or application URL settings. For WordPress, review .htaccess and permalink settings once you can access the dashboard.

If you suspect malware, restoring an older backup is not enough by itself. Thebackup may contain the same vulnerability or infected files. Have the site checked, remove unauthorized access, update vulnerable software, and rotate affected credentials before returning it to normal operation.

Keep a Clear Recovery Record for Future Changes

After testing, record which backup you restored, when the recovery finished, and any adjustments needed to make the site work. Note any customer activity that requires reconciliation, such as orders or submissions received after the backup was created.

Once the website is stable, create a fresh backup of its verified working state. Retain the earlier recovery files according to your security and retention requirements, and remove temporary archives from publicly accessible directories.

A dependable cPanel recovery process comes down to matching website files and databases, knowing your restoration permissions, and testing the result. Completing those checks before and after changes gives you a practical way to recover without relying on guesswork.

Unsure whether your website backup includes everything you need before making changes?

Contact Guru Internet Services for help understanding your backup and restoration options.

Schedule a Strategy Session!