In a previous post, I wrote about how to how to disable and limit WordPress post revisions. In this post, I will show you how to delete your old WordPress revisions and clean up/optimize your database. This ensures that your site keeps running at optimal performance.
How to delete WordPress revisions
Follow the quick and easy steps below to delete old WordPress revisions that have probably been laying around in your database for a long time.
In this tutorial, we are using our premium Perfmatters plugin. We’ve developed our database optimization feature to be as lightweight as possible, while still giving you the options you need.
If you are looking for a free solution, WP-Optimize is also good. Be careful when searching for plugins that delete post/page revisions. Some of these plugins can cause a lot of damage. Some are even banned from certain hosts due to the amount of overhead they have on your site.
No matter how good your WordPress plugin is, it’s always recommended to take a backup of your site before doing any operation that deletes data. If you are using a premium hosting provider like Kinsta, you can quickly take a snapshot of your site. This way you can rollback with a single click if needed. Otherwise, there are free WordPress backup plugins you could use.
After you have a WordPress backup, click into the Perfmatters plugin settings.
Click the “Extras” tab and then click “Database.”
Toggle on “Post Revisions.” The number of revisions found will show up to the right of it. This also includes page revisions and custom post types. In this example, you can see there are 322 revisions.
Scroll down and click “Optimize Now.”
The process will run in the background. You don’t need to stay in the plugin while it’s running or worry about leaving the window open. It will and let you when it’s finished with a notification at the top of the Perfmatters plugin settings.
I have seen dramatic speed increases by doing this on client’s sites that haven’t limited the number of revisions in WordPress. Some of them cleaning up more 1,500+ revisions.
It’s important that you give your site’s database a little TLC from time to time.
Was this tutorial on how to delete WordPress post revisions helpful? If so, let me know below in the comments.