If you have existing site that has been around for some time. You'll have to use this first.

Please note that this has to be pasted into phpMyAdmin. If you are using a different table prefix make sure you replace wp_ with your prefix

MySQL

DELETE a,b,c
FROM wp_posts a
LEFT JOIN wp_term_relationships b ON (a.ID = b.object_id)
LEFT JOIN wp_postmeta c ON (a.ID = c.post_id)
WHERE a.post_type = 'revision'

 

Next

Insert this line in wp-config.php preferable right after the <?php opening tag.

define( 'WP_POST_REVISIONS', 3 );

 

Disclaimer: The content in this post is for educational purposes only. Always remember to take a backup before doing any of the suggested steps just to be on the safe side.
Referral Note: When you purchase through an referral link (if any) on this page, we may earn a commission.
If you're feeling thankful, you can buy me a coffee or a beer