[NEW] Introducing Inline Help to Clarify Backups and Migrations
Are you wondering which WordPress files you need to back up?
By regularly backing up your WordPress website, you’ll have an error-free copy to restore if anything goes wrong. However, you might not know which files need to be backed up and when.
In this post, we’ll show you everything you need to know about WordPress backups, including which files are most important!
When you set up your first WordPress site, it won’t automatically back itself up. This makes it vulnerable to cyber attacks, downtime, critical errors, and other unexpected issues.
To protect your website, it’s important to have a reliable backup solution. By creating backups, you’ll have healthy copies of your site that you can restore whenever something goes wrong.
Often, you won’t think about backups until you really need one. However, backups should be your number-one priority to safeguard your website data.
If you want to be able to restore your entire website in an emergency, you’ll need to have a backup of all of these WordPress elements:
These work together to make your website look and function exactly the way it should. Without one, you might struggle to get your site back to the way it was before the error, malware, or other issue.
Let’s explain each of these in detail, so you know exactly which files you should back up!
WordPress core files are the foundational components of the WordPress content management system (CMS). They build the essential framework that powers a WordPress website.
With these core files, you’ll be able to:
The core WordPress files are the files in your root directory, wp-includes folder, and wp-admin folder.
You can download all of these files from the WordPress.org website. Since you can get a fresh copy at any time, you won’t always need to back them up.
In your WordPress files, you’ll also see a wp-content folder. This contains all of the content that you upload to your site.
Here’s what’s in your wp-content folder:
Additionally, you may see a mu-plugins folder that has your must-use plugins. If you run a multilingual site, the wp-content folder could also have language files. If you’re updating your WordPress site, there will also be a temporary upgrade folder.
To decide whether you need to back up your wp-content folder, consider whether you remember every plugin and theme you have installed. If so, you can always re-install these tools.
However, if you have a custom theme or can’t keep track of all the plugins you need, you should back up the plugins and themes folder in wp-content.
We’d recommend always backing up your uploads folder. If an error deletes it and you don’t have a backup, you’ll lose your media library.
Certain plugins like WP Super Cache and W3 Total Cache create their own plugin files and store them in wp-content. These plugins can regenerate these files, so you won’t need to back them up.
On the other hand, you might have a plugin like Envira Galley installed. This might create a folder to store media files for an image gallery. In this case, you’ll need to back up these extra files or folders.
There are two important WordPress files that contain information about your site’s configuration:
Your wp-config.php file is generated specifically for your website as you install WordPress. It stores crucial information about your database.
The .htaccess file contains some of your WordPress settings. For example, when you update your blog’s URL structure, WordPress rewrites this .htaccess file.
Plugins like W3 Total Cache can also edit your .htaccess file to add support for caching and optimization tools.
Although you can manually regenerate these files, it’s a good idea to back them up.
WordPress uses a MySQL database to store and organize the data from your website. This includes data like posts, pages, users, comments, and WordPress settings.
As a website owner, you’re always updating your site by adding new posts, receiving new comments, and getting new customers. This is why it’s often best to back up your database more frequently than your core files.
Now that you know more about the different parts of your WordPress site, let’s show you how to back it up!
If you have a lot of time on your hands, you could manually back up your website. As you just learned, there are many different parts to back up, so this can be difficult and tedious.
An easier solution is to install a WordPress backup plugin. There are many options available, but Duplicator Pro is the best. This powerful and flexible backup tool allows you to customize your backups, send them to cloud storage, set up automatic backups, and more!
With the free version, you can create full backups of your WordPress site. If you want more control over which files you back up, you’ll need to upgrade to a Duplicator Pro subscription.
Be sure to copy your license key. Then, open the back end of your WordPress site and install Duplicator. For help, check out this step-by-step beginner’s guide on how to install WordPress plugins.
After this, go to Duplicator Pro » Settings » Licensing:
Paste the license key you received with your purchase. Hit Activate to unlock Duplicator’s premium features!
To back up your website, head over to Packages » Create New:
Name the backup so that it’s easy to find if you ever need to restore it. Then, expand the Archive section. Here, you can decide exactly what data you want to back up:
For full backups, select all of the listed site components. You can also easily create media backups or database backups.
If you want more control over your backups, click on the Custom tab. Simply deselect any files you want to exclude from the backup.
Since core WordPress files can be re-downloaded, you might want to deselect Core. You might also want to limit the backup to just active plugins or themes, removing clutter in your backups.
When you’re finished, click Next. Duplicator will fully scan your website for any issues:
If everything looks good, hit Build. Your site will now be automatically backed up!
Once you create a backup, it’ll be added to the Packages page. You can save it to your computer by clicking Download » Both Files:
This will give you two backup files: the archive and the installer. The archive contains a copy of all the files you included in the backup. The installer will help you restore the backup on your site after unexpected issues.
When you need to restore a backup, you can upload both of these files to your root directory:
Then, paste this URL into a browser window to launch the Duplicator installer: https://your-domain/installer.php
To make this process much easier, you can set a disaster recovery point. Essentially, you’ll tell Duplicator to restore a certain backup if anything happens to your site.
Go to the backup you just created and hit the disaster recovery icon:
In the pop-up window, select Set Disaster Recovery:
You can then copy the disaster recovery link or download the launcher. Either of these will immediately launch the recovery wizard.
This will allow you to immediately recover your site, even if you’re locked out of your WordPress dashboard!
To start automating backups, find Duplicator Pro » Schedules » Add New:
Give the schedule a descriptive name. Then, choose a package template or create a new one:
You can create the template using the same steps to customize a backup. Edit the archive file to only include the data you want backed up:
When you’re finished, go back to the new schedule. Next, choose a storage location. Duplicator supports all of the following options:
After this, decide how often this backup schedule will run. You can set up hourly, daily, weekly, and monthly automatic backups:
Then, choose a Start Time, which is when the backup will start. Finally, enable the schedule and save it.
Feel free to create as many backup schedules as you want. You can back up different parts of your site more frequently than others:
By doing this, you’ll back up every part of your site at the right time!
Even without plugins, you can do a manual backup of your WordPress site. Using an FTP client like FileZilla, download all of the files in your public_html directory. You’ll also need to use phpMyAdmin to download a copy of your database as a SQL file.
If you have a file manager like cPanel, you can download both your WordPress files and database in your control panel. For more details, check out our guide on manual WordPress backups.
Most WordPress site owners should back up their websites at least once a week. Since the database is updated more frequently, you can do a daily backup of your database. Every website is different, so you’ll have to determine the best backup schedule for your needs.
The fastest way to back up WordPress is to use a WordPress backup plugin like Duplicator Pro. You can immediately compress your entire site into a single zip file, which can be used as a backup. If you need to, you can use this file for a quick migration to a new web hosting provider or domain name!
Alternatives: Some of the best WordPress backup plugins include Jetpack Backup (VaultPress), UpdraftPlus, BlogVault, and BackWPup. Jetpack is the best backup option for WordPress.com users. However, all of these will create complete backups of your site files and database.
You can back up your WordPress site by creating a package with Duplicator Pro. Then, set it as the recovery point and copy the recovery URL. When you need to restore your site, paste this URL into a browser window to launch the Duplicator recovery wizard.
We hope this guide helped you understand exactly which WordPress files you should back up!
While you’re here, you may like these extra WordPress tutorials:
Are you struggling to customize your backups? Download Duplicator Pro to easily back up the right files!
Disclosure: Our content is reader-supported. This means if you click on some of our links, then we may earn a commission. We only recommend products that we believe will add value to our readers.