1. Knowledge Base
  2. >
  3. Results
  4. >
  5. How to Generate & Download a Website Backup

How to Generate & Download a Website Backup

All of our accounts can and keep a full backup of their hosting package. This is advised as a best practice in case your content needs to be replaced or restored. The method necessary for creating a backup depends on your hosting type:

Please click on the type of backup available for your server type to be directed to instructions on creating and using backups for your server.


Third-Party Backup Services

Customers with critical business information or critical data are STRONGLY encouraged to seek a 3rd party backup service such as CodeGuard to protect against any unforeseen circumstances. Such services provide more fine-grained control over backup and restore operations, allowing them to tailor the process to suit their specific requirements. These services will also allow customers to backup cPanel accounts over the backup limits imposed by HostGator.


cPanel Backups

A full cPanel backup makes a copy of all of your files, email, databases, etc. Once initiated, you must allow the backup time to perform. The server can send you an email to an address you specify once the backup is ready to download. The steps for generating, downloading, and restoring a full backup are explained in detail below.

Note: Shared, Cloud Sites, and Reseller plans may only create cPanel backups up to 10 GB with 150,000 inodes or less. If your backup is larger than 10GB or has more than 150,000 inodes, you must contact HostGator support via phone or Live Chat for help to bypass the limit.

How to Generate a Full Backup in cPanel

 

 

You may find some links below that will redirect you to your cPanel and its features provided that the following conditions are met:

  • You are logged into your Customer Portal. You can also log in after clicking the link.
  • The hosting package you are attempting to access is either Shared or Cloud.

To Generate a Full Backup In cPanel:

 Log into cPanel.

  1. In the Files section, click on the Backups icon.

    cPanel backup icon

  2. Under Full Backup, click Download a Full Account Backup.

    Generate Full backup

  3. On the next page, select the Home Directory option from the Backup Destination drop-down menu.

    cPanel backup destination

  4. For Email Address, select whether you wish to receive an email notification once the backup is complete. (You may also change the notification email address in the provided field if you want.)backup destination option
  5. Click Generate Backup.

This will generate the backup for you and place the tar.gz file inside of your home directory. You can then download the backup via cPanel, FTP, or SSH.


How to Download the Full Backup

To download the backup from cPanel:

  1. Log into cPanel.
  2. In the Files section, click on the Backups icon.

    cPanel backup icon

  3. Under Full Backup, click Download a Full Account Backup.

    Generate Full backup

  4. Under Backups Available for Download, click the link for the backup file you wish to download.

    cPanel backups ready for download

  5. Select a destination on your PC where you would like to save the backup.

    cPanel backups ready for download

     


    How to Restore a Full Backup

    The root user must restore a full backup for the server. We will restore your full backup as long as the back was for an account previously existing on the server and you have provided the backup in the user home directory.

    Suppose you have root access to your server (which will be the case with VPS & Dedicated Server customers only) and wish to restore your cPanel yourself. In that case,  the instructions below will walk you through the prerequisites and the steps to perform the installation:

    Warning: It is strongly recommended that this process only be used for backups created by the same account from the same server that the backup was generated.

    If either the cPanel username or primary domain is different from those contained in the backup, the restore will encounter errors that will not be eligible for HostGator support.

    If either of these two circumstances applies to your restore, HostGator will consider your restore to be a migration. If any HostGator assistance is required due to these issues, please request a Website Transfer for our assistance.


    cPanel Restore Prerequisites

    To restore a cPanel account, the filename of the backup must use one of the following formats:

    • cpmove--{USER}
    • cpmove--{USER}.tar
    • cpmove--{USER}.tar.gz
    • {USER}.tar
    • {USER}.tar.gz
    • backup-{BACKUP-DATE_TIME}_{USER}.tar
    • backup-{BACKUP-DATE_TIME}_{USER}.tar.gz
    • backup-{MM.DD.YYYY}_{HH-MM-SS}_{USER}.tar
    • backup-{MM.DD.YYYY}_{HH-MM-SS}_{USER}.tar.gz

    Additionally, the file must reside in one of the following locations:

    • /home
    • /usr/home
    • /web
    • /home2
    • /home3
    • /root
    • /usr

    The file may also be selected from your local file system at the time of restore.


    cPanel Restore with Root Access
    Clients with VPS and Dedicated Hosting packages only.
    Last April 13, 2021, we recently upgraded our VPS platform to a Kernel-based Virtual Machine (KVM). At the moment, we have 2 VPS platforms that we currently support.
    • KVM VPS Accounts -  VPS accounts after April 13, 2021.
    • Legacy VPS Accounts- VPS accounts before April 13, 2021.
       

    To begin the process for a full restoration of a cPanel account on both KVM and Legacy VPS accounts. 

      1. Log into WHM as root.
      2. Search Transfer or Restore a cPanel Account at the search function at the left-hand side.

        KVM Restore Options

      3. Select either Restore with Username or Restore with File based on where you have the file stored:
        • Restore with Username: This option will search the server for backup files in the locations listed above from a file already uploaded to the server.
        • Restore with File: This option allows you to select the correct backup file from your local file system.Restore Options
      4. Place a checkmark next to Overwrite the existing user to allow cPanel to overwrite the existing cPanel account.

        overwrite existing user

    Warning: If you have a different account on this server with the same cPanel username, it WILL be overwritten, destroying the account's contents.
  6. Select whether to replace all instances of the original server's IP address with the new address or to only replace basic cPanel-provided A records in zone files (Either option should be sufficient if you are not attempting to migrate data).

    Mitigate A record

  7. Click the Restore button.

The restore process will now begin. Please be aware that the process requires active use of multiple applications, such as MySQL. Do NOT shut down or restart any processes on the server during the restore process.


Compatibility Concerns

Because of changes cPanel has made to the backup system and other system features (for example, Horde) between cPanel versions, there are several compatibility issues in the restoration process which you should be aware of:

  • MySQL and PostgreSQL database passwords:

    In cPanel & WHM version 11.42 and later, the system restores MySQL and PostgreSQL databases to the account but does not restore the user's password. This action locks the user out of the databases.

    The next time the user manages a database with the phpPgAdmin or phpMyAdmin program, the system refreshes the user's privileges and restores their access.

  • Horde:

    You cannot restore Horde data from cPanel & WHM version 11.50 and later to an earlier version of cPanel & WHM version. It is not backward compatible. Additionally, backups do not include some global Horde files.