Word press post revisions are created whenever you edit a post and click update, They are created even if you change one single character in the post. This can be useful if you ever need to revert to previous post or you need to compare older posts to more recent posts. Additionally if you have multiple people editing posts it can be used to track edits.
The down side of this if you are like me and have a large amount of posts and are constantly tinkering with them then before you know it you will have 20+ post revisions for over 300 different posts. This in turn will make your wordpress database ALOT larger than it needs to be which can damage the speed of your wordpress blog as query’s to the database will take a lot longer.
There are 3 ways we can manage post revision, the first is use a post revision manager plugin where you can specify rules and times when revisions are removed. I’m not even going to recommend one as I believe the less plug ins the better for speed of your site.
The second is is to disable the post revision feature. This can be done by opening up your wp-config.php file in your HTML editor and adding this line to the end of it.
define('WP_POST_REVISIONS', false );
This will stop all future revisions to your wordpress posts from being saved. This may be class as a little overkill so we can use a different command to store only a set amount of revisions. This command is below
define('WP_POST_REVISIONS', 5);
Where it says “5” you can obviously specify how many revisions you would like to keep.
If you would like to remove all your previous post revisions then again you can use one of many plugs, but the leaner way to do so is below.
REMEMBER ALWAYS TAKE A BACKUP OF YOUR DATABASE BEFORE EDITING IT
Login to phpMyAdmin in CPanel
Once in, select your wordpress database
Select the SQL tab from the menu, and copy and paste the command below, then apply
DELETE FROM wp_posts WHERE post_type = "revision";
All of your previous post revisions will be removed now.