Keeping an updated backup is one of the most important things you can do for your website. Disaster can hit at any time and having that backup can make the difference of getting your site back to running quickly or not at all. Just as crucial is where you store your backups. In this article weβll step through how to perform a Google Drive backup.
Lots of backup solutions allow you to store your backups on your server. Many of them do this by default. Although it is possible to store your backups on your server itβs not a good idea. Servers can crash or get hacked. If your backup is only on your server then you wonβt have a backup, which defeats the purpose of a backup in the first place.
A better solution is to store backups to a remote location that can be accessed easily from anywhere with an Internet connection. To be effective though, storing offline needs to be easy. Free doesnβt hurt either. Fortunately you can make and store backups easily, and for free, using Google Drive.
What is Google Drive
Google Drive is Googleβs free online storage service where you can store any type of file, including WordPress backup files. The free plan gives you 15 GB of storage and upgrades start at $1.99 per month for 100 GB. 1 TB is $9.99 per month, and 10 TB is $99.99 per month. The free version provides plenty of storage space for most sites.
Accessing Your Google Drive Account
All thatβs required to have access to Google Drive is to have a Google account. To see Google Drive, create or sign in to your Google account and select the square made up of dots in the upper right corner. It will open a window with lots of Google tools and services. Click the Drive icon.
Youβll see the welcome screen. If youβre using a plugin like UpdraftPlus your backups will be stored in a folder in the My Drive tab.
In order to store your backups in your Google Drive youβll need to connect your WordPress website to your Google Drive account. To do this youβll need a plugin.
UpdraftPlus
There are several excellent plugins to connect WordPress to your Google Drive account. With over a million active installs, UpdraftPlus is by far the most popular and itβs the one I like the most because Google Drive is included in the free edition. The free edition also includes remote backup to several other storage services.
For a walkthrough of UpdraftPlus, see the article The Ultimate Guide to UpdraftPlus: How to Backup, Restore, or Migrate Your WordPress Website here at Elegant Themesβ blog.
To install UpdraftPlus, go to Plugins, Add New in the dashboard and search for UpdraftPlus. Click Install and then Activate.
Once UpdraftPlus is activated youβll find it has been added to the dashboard under Settings and in the top bar. Click UpdraftPlus Backups and then select the Settings tab. Click Google Drive.
Under the storage options youβll see the Google Drive settings. Youβll need your Client ID and Client Secret. To create these, go to the API Console. The instructions are provided in the two links (βFor longer helpβ¦β or βFollow this linkβ¦β and create the API. I followed the instructions from the first link.
Creating Client ID and Client Secret
The API Console provides a list of your API projects. At the top of the screen select Create Project.
Enter a name for the project and select Create. Once the project is completed (the notification in the upper right will let you know), click the Google APIs logo to go to the API File Manager.
Here, click on Drive API. Alternately you can search for it and click on it when it comes up.
Click Enable at the top of the screen.
Select Credentials and then choose OAuth content screen. Fill in the fields and click Save.
Once youβve completed the instructions youβll be given your Client ID and Client Secret codes. Paste them into the fields. Choose which files to store, and save your settings.
Youβll see a message to authorize access to your Google Drive account. Click on the link. If youβve completed the steps youβll get another screen that asked you to authorize the connection. If you get an error, you might have to add the URL that it gives you in the error to the link it provides.
Backing Up to Google Drive
Now itβs time to create the backup. In the UpdraftPlus settings, select the Current Status tab. Hereβs where you can make backups manually. You can automate them in the Settings tab. The backup works the same. Click Backup Now.
A modal with open where you can make a few selections. Make sure the option for backup storage is selected and click Backup Now.
The backup will start and show the progress. If your website doesnβt get enough traffic UpdraftPlus wonβt have the resources it needs to create the backup. To help get around this and create the example for my test site I only backed up my plugins. Normally I would backup uploads, the database, and other files.
Once itβs completed youβll see a message that says the backup apparently succeeded.
Selecting Existing Backups shows the backups youβve created. If itβs stored on the Google Drive youβll see the Google Drive icon under the date. In this example I have an old backup thatβs stored on the server and a new backup (just of plugins) thatβs stored on my Google Drive.
To see the see the backups in your Google Drive, go to your Google Drive account and select the UpdraftPlus folder.
Within the folder youβll see your backups. Youβll notice that I have three backups but Iβve only saved one backup to my Google Drive in the example above. Two of these are from different websites. Multiple sites and backups can be saved in the same folder.
Restoring from Google Drive
Restoring a backup from Google Drive is the same process as restoring from your server. Simply select Restore and UpdraftPlus works as normal. The types of files that are available will show in the list and you can choose specific files.
For example, Iβve only backed up my plugins, but I could also backup themes, the database, and uploads.
Choose what you want to restore from the list. If I had backed up other files they would appear in this list. Click Restore.
UpdraftPlus will retrieve the files. This might take a few seconds or a few minutes. Once the files are processed youβll have to click Restore again.
Youβll see another message that tells you the restore has started. Do not stop the restore or close your browser.
When the restore is complete youβll see a message that shows what was restored.
Final Thoughts
Google Drive is an excellent choice to store your WordPress backups remotely and UpdraftPlus makes the task easy. As important as recent backups are, and considering that Google Drive and UpdraftPlus automates the task of storing them in a remote location for free, thereβs no reason not to have a recent backup.
We want to hear from you! Do you use Google Drive for your WordPress backups? Let us know about your experience in the comments.
Featured Image via Sentavio / shutterstock.com
Thank you β clear and easy to follow instructions.
what if updraft plugin start charging ¬¬
great
Or, you just use the free and Google Backup and Sync app which you download, install and backup your entire folder within about 5 minutes, without needing any direction at all.
HI Bill, how do I do this? I’m new to all this and trying to figure out the best way to do this. Your comment sounded the easiest π
do you download that to your wordpress site??
Awesome tip!
I always end up paying tons of money for storage at my hosting supplier due to my backups.
Thanks for sharing!
Ha great, thank you for the tip. After seeing three wordpress sites being hacked by not updating the plugins, this is a good idea.
Thanks. Folk may also consider Dropbox as a simple alternative, no real need to mess about with Google API Console and it supports chunked uploads too.
Question is: what happens if my site is broken and I can’t get access to the admin area. As far as I see, before to restore I first need to access the admin area. I use Duplicator Pro to create backups in Drive, it creates a sort of executable files to restore a site from the ground.
Good show! I have been using BackupBuddy and Amazon S3 for a few years now, and it provides peace of mind knowing that your site is in a secure location and also off the server. Thanks Randy, it’s nice to see some not related useful Divi stuff here and up to date…
I backup to Google Drive with Up Draft and it works great. Takes a bit of care to get it set up but very easy after that. Did a full restore of a site yesterday to show a friend and it worked flawlessly.
Thank you for all the information. I learn something with every post.
Seems like there are a few steps missing, once I get to the credentials I’m unable to create the Client ID etc. what info am I supposed to fill in on the AO content screen?
I van der that you did not use the latest version because now those frustrating guidlines are no more meededen. The processen was frustrating but niet anymore!
Sorry for the bad emglish. IT is Android translating Englisch
Thanks! I may move from BackWPup to Updraft. Would like to know if FTP and Google are on the free verses and what the limitations are.
No ftp in the free version.
*versions