Once you start using WordPress, you’ll quickly discover that the Content Management System (CMS) comes with tons of tools for blogging. In particular, the WordPress revision history feature can be extremely useful. However, if you want to keep your site performing optimally, it’s important that you learn how to manage post revisions effectively.
Fortunately, this process can be pretty straightforward. As long as you follow some best practices, like deleting unnecessary revisions, your site’s performance shouldn’t be affected.
In this post, we’ll take a closer look at WordPress revision history. Then, we’ll share three crucial tips for managing your post revisions. Let’s get started!
A brief introduction to WordPress revision history
Before we show you how to manage post revisions, let’s quickly look at how to find them. To access your WordPress revision history, navigate to your dashboard and open any post you want. Then, click on the gear icon in the upper right corner of your screen to access the post settings:
Select the Post tab and scroll down until you locate Revisions. Here, you’ll see the number of versions currently available:
Once you click on the Revisions tab, you should see something like this:
This screen shows you the current version next to the previous one. As you can see, it’s in code format, but all changes are highlighted in red and green.
Just above the Title of the post, you’ll be able to see some crucial details about that revision. For instance, the date and time it was made, as well as the author who made those changes.
You can also click on Previous or use the timeline to browse older revisions. Then, you can select Restore This Revision if you want to replace the current version with an older one.
There are many scenarios when you might need to access your WordPress revision history. For example, if there’s a connection problem while writing a post, you won’t have to worry about losing all of your content. You can simply restore your most recent revision.
Furthermore, WordPress revision history can be extremely useful to editorial teams and proofreaders. Different authors and editors can keep track of changes made to a post.
Tips for managing your WordPress revision history
Now that you know a bit more about WordPress revision history (and how to find it), let’s look at three key tips for managing your post revisions.
1. Delete WordPress post revisions
Having too many post revisions can clog up your WordPress database, so you might want to delete them. Let’s look at two different ways to do this:
Delete WordPress post revisions using a plugin
If you want to delete WordPress post revisions, the simplest option is to use a plugin like WP-Sweep. To get started, go to Plugins > Add New in your WordPress dashboard. Then, search for the tool:
Click on Install Now followed by Activate. After that, go to Tools > Sweep:
On this screen, you’ll see the Post Sweep section at the top. Under Details, you’ll find some data regarding your content. For example, you’ll be able to view the number of revisions, auto drafts, deleted posts, and more:
If you keep scrolling down, you’ll see that WP-Sweep also enables you to “sweep” your comments, users, and more.
Next to Revisions, you can click on the Details button in order to review the posts that are associated with the revisions. Once you’ve verified that it’s safe to delete them, you can go ahead and click on Sweep.
When the process is complete, you’ll be able to see the number of revisions that you’ve successfully deleted:
It’s as simple as that!
Delete WordPress post revisions manually
If you don’t want to install a plugin on your site to delete WordPress post revisions, you can do it manually. However, this method is only recommended if you’re an advanced WordPress user. As a precaution, you’ll want to back up your site in case something goes wrong and you need to restore your deleted content.
When you’re ready, you can log into your hosting account and access your control panel. Then, go to phpMyAdmin and navigate to the SQL tab.
Here, you’ll need to run the following line of code:
DELETE FROM wp_posts WHERE post_type=”revision”;
Keep in mind that you will need to replace wp with your own WordPress database prefix.
2. Limit saved WordPress post revisions
When it comes to managing your WordPress revision history, deleting old versions of posts is an excellent start. However, this won’t stop future post revisions from being generated. Therefore, you may want to put a limit on saved WordPress revisions so you don’t have to delete them.
Limit saved WordPress revisions using a plugin
You can easily limit saved WordPress revisions by using a plugin like WP Revisions Control:
After you’ve installed and activated the plugin, go to Settings > Writing. Then, scroll down to locate the WP Revisions Control section:
Here, you’ll be able to set a limit for Posts, Pages, Custom CSS, and more. In order to provide yourself some wiggle room in case of emergency, set your post revisions limit to ten. Make sure to click on Save Changes when you’re finished!
Limit saved WordPress revisions manually
If you’d like to limit saved WordPress revisions manually, you’ll need to modify your site’s wp-config.php file. This is only advisable if you already have some experience managing your site’s files. Tinkering with important files can damage your site if you’re not careful.
First, you’ll need to connect to your site using an SFTP client such as FileZilla. Then, locate your root directory, which is typically labeled public_html. The wp-config.php file should be inside it.
Once you find the file, open it and add the following line of code:
In our example, we’ve used “5” as the limit. Feel free to modify this number to reflect your personal preference. When you’re done, save the file.
3. Turn off WordPress revisions
Deleting and limiting WordPress post revisions can help you manage your database and keep your site running smoothly. However, if you know for certain that you won’t be needing a WordPress revision history, you may want to turn it off entirely. We’re going to show you two ways you can do this.
Turn off WordPress revisions using a plugin
You can easily “turn off” or disable WordPress revisions using a plugin. For this method, we’re going to use Disable Post Revision:
Once you’ve installed and activated the plugin, go to Settings > Writing. You’ll now see an entirely new section for Disable Post Revisions:
To turn off WordPress revisions entirely, simply select Posts from the menu and click on Save Changes. Note that you can also disable revisions for Pages, Media, Custom CSS, and much more.
Turn off WordPress revisions manually
If you want to minimize the number of plugins on your site, turn off WordPress revisions manually. To do this, you’ll need to introduce changes to your wp-config.php file. As a reminder, this is only recommended for advanced users who are comfortable with WordPress file management.
Simply locate the wp-config.php file in your root directory and add the following line of code:
define('WP_POST_REVISIONS', false );
Then, make sure to save the file.
When you’re working with blog posts, a revisions archive can give you added security and help streamline the editorial process. However, if your site is accumulating and storing too many WordPress revisions, it can bog down your database. This may negatively affect your site’s performance and rankings in the search results.
Fortunately, there are a few best practices you can follow when managing your WordPress revision history. You can start by deleting any unnecessary post revisions. It’s also a good idea to limit the maximum number of post revisions that can be saved. This way, you don’t have to wipe them regularly. Alternatively, if you know you’ll never need post revisions, you can disable them entirely.
Do you have any questions about managing your WordPress revision history? Let us know in the comments section below!
Don’t forget to join our crash course on speeding up your WordPress site. Learn more below: