Many hosting providers mention free backups as one of their highlighted features. These backups are most probably stored on the same server as our website. So if our hosting provider loses the data on the server due to physical damage or hacking attempt, our website together with all our back up files is lost. Also hosting provider can cancel our account due to some policy violation leaving us with no option to restore our site.
So it is always better to have an alternate backup system in place. This system should be completely independent of our hosting provider and should be easy to set up. Another important feature that a good backup system should have is the ability to create automated backups as it is not practical to create manual backups on a daily or weekly basis. There are several free WordPress plugins available that help us to schedule automated backups periodically. In this blog, we will see the step by step process to schedule automated backups and then restoring the site from these backups.
Scheduling and Creating Automated Backups
Step1: Install and activate the Updraft Plus plugin. This plugin has more than 2 million active installations and has exceptionally well user ratings. After installation, we have to go to Updraft Plus Backups section under the settings menu in the admin dashboard.
Step2: Now we can go to the settings tab on the plugin page. In the settings section, we have the options to provide the backup frequency for both files as well as the database.
The frequency setting is important and is dependent on the type of blog we are running. Suppose our blog is related to news and gets new content every day then the database backup should be taken daily. On the other hand, if we have a blog that publishes articles once in a month then daily backups may not be necessary. In that case, we can schedule the backups with a weekly frequency. But if we receive frequent comments for our blog, it is better to have a daily backup as we may end up losing some valuable comments with a weekly backup frequency. For blogtriangle, I keep a daily backup.
Files in our WordPress installation get updated only if we have any updates to our plugins or themes. As this does not happen frequently like a database we can set the file backup frequency to a week. Another option on the settings page is to set the remote storage location. This is highly recommended and is not an optional set up if we are serious about our blog. As mentioned before, if by any chance the data in our server get corrupted or lost, a remote backup is essential to restore our website. The free version of this plugin provides us with the option of selecting a single remote storage location whereas in the premium version we can choose multiple remote storage locations.
In our tutorial, we are choosing Google drive as the remote back up location. We will be going to our Google drive and providing permission for this plugin to access our Google drive later. Another option in the settings tab is to select the type of files to include in the backup. It is better to include all the available options as shown below.
After selecting all these settings click the Save Changes button at the bottom.
Step3: Now a new pop up message will appear with a link to redirect us to Google drive
We need to provide permission to Google drive so that this plugin can access our drive and save our backups.
Once we provide access by clicking the Allow button as shown in the above image a new page will appear.
Click the Complete setup button on this page to successfully complete our remote storage set up with the Google drive. This process will also redirect us back to our plugin settings page.
Step4: In the settings page click the Backup Now button to create a new backup. A new screen will appear with options to include files, databases, and another option to send the backup to a remote location.
Step5: Once the backup is successfully created we can go to the existing backups tab and view different backup files separately. Similarly, we can go to our Google drive and view the backup files.
Restoring website from server backups
We have already learned how to schedule and create automated backups for our WordPress site in the above process. Now let us see how we can restore our WordPress site from backup, in the case of any unexpected event that led to a site crash or data loss. To test the restore process, we are going to delete some of our posts, activate some new plugins, and change our theme.
Initially, we had 1002 published posts.
Now let us delete some posts. Now we have 991 published posts.
In the case of plugins, we have activated 4 new ones.
We have also changed the theme to the free ultimate blogger theme.
Now let us start the restore process by clicking the Restore button on the plugin settings page. This will take us to the existing backups section.
Click the Restore button again. A new screen will appear with the options as shown below.
As we have made the modification to themes, plugins, and content we have to check all the available options and proceed to restore. A confirmation message will appear. We have to click the Restore button again to proceed with the restore process.
Once the process is complete a success message will appear.
This will restore our theme, content, and plugins back to the original state.
Restoring website from remote backups
We have already set Google drive as our remote back up media in Step2. So we can now login to Google Drive and download the backup files. There will be separate zip files for database, plugins, themes, etc.
Now to restore our site from these downloaded back up files first we have to upload these files. For this go to the Existing Backups tab in the settings page and click the Upload back up files link on the More tasks section. Now an option will appear to upload the backup files.
After successfully uploading the files, we can go to the Existing backups section to view these backup files. The process of restoring our site is now exactly the same as mentioned before.
Thus we have learned how to schedule automated backups In WordPress for free.
Note: Setting up an automated backup schedule is not going to protect our WordPress site from the site crash due to hacking attempts. Backups just provide insurance in the case of any unexpected data loss. Therefore it is always essential to secure our WordPress installation from hackers by using 2-factor authentication methods like Google ReCaptcha, Google Authenticator, and login security questions. I have also explained in detail about some simple steps to secure a WordPress login. We can easily implement these techniques to create a secure WordPress installation.