How to Disable or Limit Post Revisions in WordPress

Share This Article:

WordPress creates revisions to posts and pages which are automatically saved it the database. Any small change made to a post will be saved as a revision, hence there will be many revisions for each post. All the old post revisions are never deleted, hence increases the load on database. It is necessary to disable or limit post revisions, simply follow this tutorial to do so.


Read This : How to add 3 column footer to WordPress theme

Disable Post Revisions in WordPress

Open you WordPress installation folder, edit wp-config.php file and add the below code to it and save it.

// Completely disable post revisions
define('WP_POST_REVISIONS', false);

Functionality of Code:

  • This will completely disable post revisions in WordPress.
  • It is not recommended to disable post revisions, so try to limit them using code below.

Also Read : How to display related posts in Genesis Theme without a Plugin


Limit post Revisions in WordPress

Add below code to wp-config.php file and save it.

// Limit post revisions in WordPress
define('WP_POST_REVISIONS', 2);

Functionality of Code:

  • This will limit post revisions to certain value.
  • In this case, the value is '2', means two post revisions and one auto-save.
  • Change the value to any positive integer, it works.

Hope you like this article on how to disable or limit post revisions in WordPress. If you got any query regarding this, please do post a comment.

Genesis is the most flexible WordPress theme framework that comes with tons of options. We have been using Genesis on all of our blogs and recommending the same to you. Every bit of it is coded according to the standards. Give it a try!


  1. Great post, thanks for the tip. I think I prefer to reduce it than disabling it.

Speak Your MindComments Policy →


Looking for More Awesomeness?