How to backup and restore a MySQL database in cPanel?

Our cPanel hosting makes database backup and restoration very simple, allowing you to do this with a few clicks. Once you have logged into your cPanel, go in to the Backups section. From here you will see the “Download a MySQL Database Backup” option, with your databases listed below this. To download a database backup, simply click on the database name and it will download a zipped backup of your database in .sql.gz format. This is the gzip format, a linux archiving file format, you can extract this on Windows using a variety of tools such as WinRAR or Winzip. Once extracted you will be able to view the sql commands that create your database and all the data inside it if you wish. This is purely optional if you wish to take a look at the database structure from your MySQL hosting, once you have downloaded the .sql.gz file this is the backup of your database and what you should keep safe in case a restoration is needed.

To restore your database is just as simple as taking a backup, again go to the Backups section of your cPanel hosting account. From here go to the “Restore a MySQL Database” section and click the choose button, in the popup window locate the backup that you have previously taken, this should be the file in .sql.gz format. Once you have selected this, simply click the upload button and your database will be uploaded to the server and restored from the backup version!