How to Manually Backup Your WordPress Website


Doing a constant maintenance on a website is almost as important as building one, and backing up a website is the most crucial step in the maintenance process. If you’re new to WordPress, this particular article will serve as a guide for you to know why and what needs to be done keeping a backup of your entire website files, emails and the database.

Don’t assume your web hosting provider is doing backup for you. It is your responsibility to keep a regular backup of your site somewhere on your system or in an external drive for safe keeping when the need arises.

No website is 100% free from hackers and that is one of the reasons why backup can be a bail out for you whenever an attack occurs that caught you on aware.

Keeping an up-to-date copy of your website is important. Your site could get defaced or broken by intruders using several vulnerabilities identified with your site, it could fall victim to an attack, or you could make an error on the site; for example, something could break while you’re updating an aspect of your site. If you have access to a backup, you’ll be able to restore the backup, returning your website to its normal state.

Preparing to Backup a WordPress Site Manually

Manually backing up a website will require you to log into the server and export the two core components, the site files and database, from two different locations. The site files will be located within the File Manager console of your server, while your database can be accessed through phpMyAdmin.

Before you begin, a good practice for this process is to create a folder on your computer and rename it as either your or your client’s business name and follow the name with the date of the backup. Within this folder, create two subfolders called “Site Files” and “Database”.

How to Manually Export Your WordPress Website’s Database

To begin, log in to the admin interface of your website’s cPanel using either your chosen login details or those shared with you by your client.

Log into cPanel

WordPress uses a MySQL database system to operate. Web developers can interact with the website’s database through the phpMyAdmin console. The database stores a number of indexes, users, tables and more, each which contain various systems and processes relating to the functioning of the website. To export the database, click on the Databases dropdown and select phpMyAdmin. Once selected, the phpMyAdmin console will open in a new browser tab.

Click the phpMyAdmin tab

Once you’re inside phpMyAdmin, look on the left-hand side panel and select the database of the website. If the server itself is hosting a number of websites, you’ll see a list of available, linked websites. Once you’ve selected the correct database, the right-hand panel will display all of the tables associated with the site.

Now, click on the tab that says “Export”. Note, in other servers it may be required to scroll down to the bottom of the table list and click a checkbox that says ‘Select All’ before clicking on the “Export” tab.

Select ‘Click’ and click Go

Once you’re in the Export console, you’ll be met with a few input options:

  1. Select Quick as the Export method
  2. Select SQL as the Format option
  3. Click Go

A file should automatically start downloading and will save to either your Downloads folder or similar. Once the download has completed you should see a file with the suffix .sql saved on your computer. Move this file to the subfolder named “Database”.

Move the .sql file to the ‘Database’ folder

For whatever reason, should the database not automatically download, it may display directly within your phpMyAdmin console. If this happens, simply copy everything in the display box and paste it into a new IDE file (Sublime, Brackets or your computer’s default TextEdit). Once pasted, save the file as db.sql, companyname.sql or similar, and move it to the relevant folder.

 

Exporting Your WordPress Website’s Site Files Using CPanel

Once you’ve logged into CPanel, navigate to the dashboard and select the File Manager option.

Click the File Manager tab

In the File Manager, navigate to the right-hand column and select the folder named ‘public_html’. Note, you may have to move around between folders. Once you’ve located public_html, click on the folder name (not double-clicking on it as this will open the folder) and click Compress.

Compress the public_html folder

A pop up will appear. Select .zip Archive then click Compress File(s).

Select ‘Zip archive’

Once the files have been compressed, click on the ‘public_html.zip’ folder and click Download.

Click Download

Once the download is complete, remember to delete the .zip file as it’ll take up unnecessary space on your server. To do this, click on the ‘public_html.zip’ folder and click Delete.

Delete the .zip file

At this point, locate the .zip file and move it to the Site Files folder.

Move the public_html.zip file to the Site Files folder

Great! You’ve successfully exported your website’s site files!

If you are unable to export the site files directly from the cPanel, you’ll need to use an FTP client to connect to your website’s server. This will be explained in another article.