You need to be sure to have backups of your key data

Backup WordPress Files and Database Automatically to Avoid Catastrophe

| 12 Comments

It’s a piece of advice that you’ll get told over and over again as a WordPress site owner, but there is a very good reason – BACKUP YOUR DATA. Even if you think you’re undertaking a simple little change, a wrong move could result in lost data or files which, without a backup, is generally unrecoverable. Even if you take a backup before you make changes, hardware failures or hackers could wreak havoc on your files and/or database, so it is extremely important to keep regular backups of your content, so that you can restore your site should the worst happen.

You could do it manually and download everything once a day, but that gets extremely tedious in a hurry. Instead, you need a solution that will do it in the background without you needing to worry about it and that’s where Updraft comes in.

Updraft – the backup plugin

Updraft seems to be a relatively unknown plugin and I don’t know why because it is fantastic. It takes your essential files (themes, plugins and uploads folders) and your database and backs them up to any of the following services:

  • FTP
  • Email
  • Amazon S3
  • Rackspace Cloud

FTP is a very feasible solution, so long as the server you are backing up to is a different server to the one your site is hosted on; if your hosting server dies, then your backups will be no good if they’re on the same server.

Email is good too, but space and size limitations can stop the files reaching you. Additionally, your email needs to be stored on a separate server for the reasons described above. A good solution to the size limitation would be to use YouSendIt to backup files.

I’ve had no experience with Rackspace, but I’m going to walk you through sending your files to Amazon S3.

Firstly, you’ll need an S3 account. Before you start getting concerned, they have a “free tier”, which should accommodate most lighter users. The exact pricing details can be found on their website, but most small sites won’t incur any charges and the fees for heavier users are still very reasonable.

Once you’ve got your S3 account set up, you’ll need to set up a “bucket”. This is a unique folder name that will store your files. You can do this by going to the console and clicking on Create Bucket.

Once you’ve created your bucket, you’ll need to get your access key and secret key (like a username and password, so keep them private). Go to Your Account and then click on Security Credentials. There, you will be able to create a new Access Key. Keep that page open so that you can copy your access key and secret key in a minute.

How to set up Updraft to use Amazon S3Now go back to your WordPress site and install Updraft. Once it’s installed, go to the settings page.

  1. Select Amazon S3 as your Cloud Backup Service.
  2. Decide how frequently backups should be taken (daily should be adequate for most sites).
  3. Enter the number of backups you would like to keep. For example, if you select 30 and you’re taking daily backups, on the 31st day, the 1st backup will be deleted to make way for your new backup.
  4. Enter your Amazon S3 access key, secret key and bucket name.
  5. Select whether or not you want an email every time a backup is performed.
  6. Save your settings.
  7. Perform a test by forcing a backup and seeing whether you see your files in your Amazon S3 console.

Now you can rest in the knowledge that no matter what happens to your site, you’ll always have a backup that is no more than one day old.

Had you heard of Updraft before? Have you installed it and got it working? Do you have any horror stories of losing your site without a backup?

Categories: Plugins, Security, The Basics | Permalink

What next?

Hire me

If you couldn't quite manage this yourself, find it too intimidating, or just don't have the time to do it, you can always hire Dave to do it. Please get in touch so that we can discuss your needs.

Leave a comment

If you have a question, update, or comment about the tutorial, please leave a comment. I try and respond to every comment, though it may take a few days, so please check back soon.

Keep your site backed up, updated & secure

I provide a service called The WP Butler, which helps you stay on top of the maintenance of your WordPress site. Instead of worrying about whether your site is secure, updated and backed up, The WP Butler handles all that for you on a regular basis, so that you can focus on doing what you do best. If you use coupon DIWW, you'll save 15% on our already-low-prices for all maintenance plans.

Author: Dave Clements

Dave Clements has been building websites for close to a decade and in 2010, he formalised that by starting his own company, The UK Edge. He now works on a variety of web projects, from simple tasks like installing a new WordPress site, to consulting on problems, or redesigning his clients' sites. He also runs Do It With WordPress, a site dedicated to providing free tutorials on WordPress. When he's not building your new website, you can find Dave eating Wheat Thins, spending time with friends and family, watching Indie films, fostering kittens from the local Humane Society, listening to some dubstep, dance and electronic rock, and exploring the world.

12 Comments

  1. WP Time Machine works well, too. And adds Dropbox to the mix of destinations (provides FTP & S3 support too).

  2. What about Automatic WordPress Backup? It works great with Amazon S3. Full daily updates.

  3. I’ve been using WordPress Backup to Dropbox. It was quite simply the first plugin I stumbled across that didn’t put up a big roadblock preventing me from using it. I had a Dropbox account and there was no need to (figure out how to) set up a cron job.

    I like that the author of Updraft has made an effort to build in a restore feature. But I’m guessing it doesn’t work for email backups, which would negate any benefit that could have for me.

    • I’m intrigued about this WordPress Backup to Dropbox that you mentioned. I’ll have to look into that.

      As for the restore feature, I don’t see why it wouldn’t work with email backups. It depends on whether you also store the backups on your server (which you should).

      Thanks for stopping by

  4. Ah, I am a little intimidated by this since I am a newbie and it seems like a lot of work? What about just using the Tools>Export Function when you make changes or post?

    • Well, you can, but there’s a couple of problems with that:

      You don’t get an entire dump of your database, so you won’t have all of your settings saved.You have to do it manually – the main point of this is automating it, so that you don’t have to worry about it!

  5. Hey,

    What do you guys think about BlogVault. Last year i went with this service mainly because it was fairly cheap – around $30/year. However, my subscription is about to end and they’ve “upgraded” the prices to $9 per month (the cheapest plan).

    Even tough i have this backup service/plugin for almost a year i never used it so I’m wondering if its worth it.

    I’ve also heard of the backup service made by the creators of WordPress but that’s even pricier.

    Do you recommend going for a free plugin (like Updraft or WP Time Machine) instead of Blogvault or other similar services ?

    Thanks

    • I’d definitely stick to a free plugin. They do the job and it doesn’t need to be fancy; it just needs to have a backup waiting for you in the case of a catastrophe. I personally use Updraft and it suits me just fine.

  6. I’ve been using WordPress Backup to Dropbox. Even tough i have this backup service/plugin for almost a year i never used it so I’m wondering if its worth it .i’hv got my problems solved..

Leave a Reply