WordPress is a strong and solid web publishing application, but since it’s hosted on a web server and data is stored in a database, it’s crucial to backpack your blog or WordPress website quite frequently just in case catastrophe strikes and you lose all of your content… and thus… no more blog or website…poof… all gone. By backing up your site frequently, you will be able to restore your site to what it was before it was obliterated into nothingness. It’s always better to be safe than sorry.
You should always run backups on three important elements of your site:
1. the database
2. wp_content folder – which has your themes, plug-ins and uploaded content
3. wp_config.php file – which holds your access information.
I know it seems like a huge chore to have to backup all of this information, but believe me, if something goes wrong, you’ll be happy you did.
Let’s look at the database backup first. There is a simple, automated way to back up your database which is much better than doing it manually. A manual backup, I admit, is a lot of work. WordPress offers a great plugin that makes database backup a breeze.
To install the plugin, go to Plugins, Add New, then search for WP-DB-Backup (by Austin Matzko). Click install now, and activate it. The database backup plugin will appear under Tools in your WordPress dashboard. So, click on Tools, and then Backup. This plugin, by default, will backup your entire database. It even copies your spam comments and post revisions. You can exclude those by checking the boxes, but I suggest leaving them in so that you have a complete copy of everything you had.
Then you have two option for backup. You can either backup immediately, or you can schedule backups. I suggest scheduling backups. If you add content to your blog or site on a daily basis, choose once hourly or twice or once daily. If you post once a week, then a weekly backup should be sufficient. You may want to set up a Gmail account to receive the backup emails if you do a hourly or daily backup since you’ll keep getting backup emails, which can get irritating after a while. So, type in your email address in the box and click schedule backup. If you want to, you can also run a backup right away by going to the Backup Options section and choosing Email backup to: with your email address and clicking Backup now.
So, that was how to backup your WordPress database files. Step 2 is to backup your themes, plug-ins and uploaded content. These are all located in your wp_content folder. You’ll need to create a folder on your computer that is specifically for these backup files. You can call it WPbackup and place it where you will be able to find it later, like in your documents library, or wherever you like. This is the folder where you will place your backup files. The way to do this is by using your FTP, browse to your blog files, find a folder named wp_content, and simply drag the wp_content folder into your new backup folder on your computer. This lets you backup your themes and plugins, plus all the other files you’ve uploaded onto your site, including videos, photos. it even backs up all the upgrades for your theme and plugins. I recommend you do this back up at least once a month, by just dragging the new wp_content folder from your FTP into your backup folder on your computer. it will simply overwrite the old content, and add in any new content. If you want, you can even date your backups so that you will know when you did your last backup. Once a month should be sufficient.
Step three, is backing up your access information. Go back to your FTP client and find a file called wp_config.php. Drag this into your backups folder. This file contains the code configurations that shows how WordPress communicates with your database. It’s important to back this file up because if catastrophe strikes and your WordPress crashes completely, you can actually replace every single file in the WordPress installation, except for the wp_config.php file and wp_content folder. When you drop in these backed up files, your WordPress will come back up and work properly. So, if disaster strikes, all you need to do is clear out your FTP of all files, then bring in a fresh copy of WordPress, then bring in your backed-up wp_config.php file and your wp_content folder. Then everything will go back to normal.
Running complete and continuous backups of your database, themes, and uploaded files, along with your access files will ensure that if anything does go wrong with your site or blog, you can always restore it quickly. Doing backups may seem like a hassle, but if something does go wrong and your site or blog gets wiped out, you’ll be so happy you did.