WordPress Delete Revisions: The Ultimate Guide
Bulletproof Backups for Your WordPress Website
Fortify your business continuity with foolproof WordPress backups. No data loss, no downtime — just secure, seamless operation.
If you’ve landed here, you already know the problem: old post revisions are bloating your database. Your diagnosis is spot on.
Now you just need the “how.” Deleting anything from your database can feel risky, and you absolutely want to do it the right way.
That’s exactly what we’ll show you in this WordPress delete revisions guide.
TL;DR: Deleting your WordPress revisions can significantly improve your site’s performance. However, it is crucial to always back up your entire site first to avoid data loss or site issues from incorrect queries or accidental deletions. This precaution ensures you can restore your site if something goes wrong.
What are WordPress revisions?
WordPress revisions are like the version history for your posts, pages, or custom content types. Each time you click on Save Draft or Update, WordPress saves a snapshot of your changes. These revisions capture and track every change you make to your content, allowing you to monitor alterations over time.
One of the major benefits of revisions is that they allow users to compare different versions of their content. This makes it incredibly easy to pinpoint specific changes, correct mistakes, or recover previous versions if necessary. Whether you’ve accidentally deleted an important section or simply want to revert to an earlier draft, WordPress revisions provide a safety net for content management.
However, despite these advantages, it’s essential to manage revisions properly. Over time, an excessive number of revisions can impact your database size, leading to a slower, less efficient website.
By regularly deleting unnecessary revisions, you can improve your site’s performance, ensure quicker load times, and maintain an optimized database.
☄️ Note: Always use a reliable backup plugin to backup your entire site. If something were to go wrong during revision deletions, you would have a safety net to fall back on.
Methods to delete WordPress revisions
To keep your WordPress site running smoothly, it’s important to periodically delete unnecessary revisions. Here are some methods you can use to clean up these revisions:
A) Use a plugin to delete revisions
Using a plugin is the safest approach. We recommend Companion Revisions Manager for this task because it’s a focused tool with no confusing extra options. Here’s how to use it:
First, get the plugin running and open its settings. Head to Plugins > Add New to install and activate Companion Revisions Manager. Immediately after, go to Tools > Revisions in your main menu to open the control panel.
Finally, delete all the revisions. Inside the settings, you will see a button labeled Delete existing revisions. Before you click it, just double-check you have a recent backup of your site. Once you’re ready, click the button to Delete existing revisions.
B) Manually delete revisions
If you don’t want to add another plugin, you can delete revisions manually. This method uses phpMyAdmin, which is the standard tool for managing your site’s database. This approach is very direct. But it requires your complete attention.
🦁 Note: You are about to make permanent changes to your website’s database. One small mistake can take your entire site down. Please, make a full backup of your website right now. This is the one step you cannot skip.
First, you need to access your database. Log in to your web hosting control panel. This is usually called cPanel or something similar. Look for the phpMyAdmin icon and click on it. This will open the main database tool for your site.
Next, you have to select the correct database and find the SQL tab. On the left side of the screen, you will see a list of databases. You need to choose the one that belongs to your WordPress site. A useful tip is to look for the one with tables named wp_posts and wp_users. Once you click it, a new set of tabs will appear at the top. Click on the one labeled SQL.
Finally, you will run the delete command. Carefully copy and paste the following command into the large text box. DELETE FROM wp_posts WHERE post_type = "revision";
Before you continue, check your table prefix. Most sites use wp_, but yours might be different. Look at the table list on the left to confirm. If your prefix is wp123_, you must change wp_posts in the command to match. Once you are sure the command is correct, click the Go button.
🌸 Note: To prevent revisions from building up again, you can use a plugin to set a limit to your revisions. Or, for a permanent fix, add define(‘WP_POST_REVISIONS’, 3); to your wp-config.php file.
Benefits and drawbacks of WordPress delete revisions
It’s easy to think of revisions as just junk to be deleted. But honestly, they do have their moments. Understanding both sides helps you decide how to manage them, not just delete them.
The case for keeping revisions
The reason you’re here: the downsides
Troubleshooting common issues while deleting revisions
Sometimes things do not go perfectly. If you run into an issue, it is usually one of these common problems. Here are the simple fixes we use when they happen.
The process times out before it finishes
If you have thousands of revisions, a plugin might fail trying to delete them all at once. This happens when the process takes longer than your server allows.
Use a plugin that deletes revisions in smaller groups, like WP-Sweep. This helps avoid server timeouts. If that is not an option, you can ask your web host to temporarily increase your site’s max_execution_time.
A plugin seems to be causing a conflict
Plugin conflicts are common. You click the delete button and nothing happens. Or maybe your revisions list suddenly disappears from the post editor. This often means another plugin is interfering.
The fastest way to find the problem is to temporarily deactivate your other plugins one by one. A good tip is to start with caching plugins or any other database tools, as they are the most likely to cause a conflict.
Your site slows down during the cleanup
Deleting a very large number of revisions can put a temporary strain on your server. This can make your website feel sluggish for you and your visitors.
Just run the deletion process during a time when you know your site has very little traffic. For most sites, this is late at night.
You see a database error after a manual delete
This is the most serious issue. It almost always happens because of a small mistake in the manual SQL command.
This is exactly why we insist on a backup. Your first and only action should be to restore your site from the backup you made before you started. The most common error is a typo in the table prefix (the wp_ part). To be safe, always test your command on a staging site before running it on your live site.
Now that you know how to handle the cleanup and any potential problems, you’re in full control of your site’s performance.
Parting thoughts
Deleting WordPress revisions can significantly improve your database performance and speed up your site. Note that it is non-negotiable for you to take a backup of your entire site before performing any additions or deletions. Consider investing in a good backup plugin like BlogVault.
For a straightforward, automated approach, consider using plugins that handle the process for you. However, if you prefer having more control, manually deleting revisions through phpMyAdmin is an option—just be sure to follow the steps carefully to avoid issues. Limiting the revisions stored in your wp-config.php file can also help prevent future database bloat.
Regular maintenance of your revisions is essential to ensure your content remains intact and your site stays optimized.
FAQs
How do I delete revisions on WordPress?
Deleting revisions on WordPress can be done by using a plugin like Companion Revision Manager. Alternatively, if you prefer a more hands-on approach, you can manually delete revisions using SQL queries through phpMyAdmin. But always remember to back up your site before making any deletions!
How many revisions does WordPress keep?
By default, WordPress saves an unlimited number of revisions for your posts and pages. This means every time you click Save Draft or Update, a new revision is stored. However, you can limit the number of revisions by adding the following line to your wp-config.php file: define('WP_POST_REVISIONS', 5); This limits the revisions to the last five changes.
Where are WordPress revisions stored?
WordPress revisions are stored in your site’s database, specifically in the wp_posts table. Each revision is treated as a separate entry tied to the original post or page. Over time, these entries can accumulate and bloat your database, affecting performance.
Do revisions slow down WordPress?
Yes, accumulating numerous revisions can slow down your WordPress site. Every stored revision adds to the database size, which can lead to slower query times and overall reduced performance. Regularly cleaning up unnecessary revisions can help keep your site running efficiently.
Does WordPress automatically save changes?
Yes. WordPress autosave functionality automatically saves your post or page every 60 seconds while you’re editing. These auto-saves are designed to prevent data loss in case of browser crashes or internet issues. Auto-saves are also stored as revisions in your database.
Tags:
Share it:
You may also like
MailPoet vs Mailster: An Honest Review to Help You Decide
Newsletter plugins are essential for growing your audience. You’re smart to be careful with your choice. A bad pick can lead to slow sites and frustrating plugin conflicts. The good…
MailPoet vs Brevo: The Best Tool For Your Email List in 2026
Picking from the sea of WordPress newsletter plugins can be a headache. You’ve likely narrowed it down to MailPoet vs Brevo, but now you’re stuck. They represent two very different…
The Ultimate Mailster Review: Read This Before You Buy
Looking for a newsletter plugin that brings marketing to WordPress? As a serious user, you’re past the basics. You’re ready for a system that doesn’t penalize you for growing your…
How do you update and backup your website?
Creating Backup and Updating website can be time consuming and error-prone. BlogVault will save you hours everyday while providing you complete peace of mind.
Updating Everything Manually?
But it’s too time consuming, complicated and stops you from achieving your full potential. You don’t want to put your business at risk with inefficient management.
Backup Your WordPress Site
Install the plugin on your website, let it sync and you’re done. Get automated, scheduled backups for your critical site data, and make sure your website never experiences downtime again.