Disable and Limit WordPress Post Revisions




Disable and Limit WordPress Post Revisions

Disable and Limit WordPress Post Revisions

WordPress is the number one CMS in the world. Default WordPress editor save every single post revision in the system database for future uses. It also easies to limit WordPress post revisions depends on user demand. Someone like to save all revisions and other people try to save database space deleting unnecessary post revisions. As an advance CMS you can easily disable or limit 1, 2, 3 - 100 post revision editing wp-config.php file.

Why limit Post Revisions?

You don't know how many revisions it saves in the database. Suppose, you published about 100 articles to your website. Before publishing, you write the article and save again and again using WordPress post or page editor. Every time it saves a revision under the post ID. If you have saved an article 50 times, your website will store 50 revisions of the article. So things about 50 articles. This unnecessary content increases the size of your database as one article with 50 revisions.

My personal recommendation changes the number of revisions that are stored. On my personal websites, I limit revisions to 3 (three). This allows me to refer back to the last 3 copies of an article, without taking up too much size in the database.

Disable and Limit WordPress Post Revisions

Limit WordPress Post Revisions

To change revisions of WordPress post without plugins add the code snippet below to wp-config.php.

define( 'WP_POST_REVISIONS', 2 );

Disable WordPress Post Revisions

Disable Revisions using the following code.

define( 'WP_POST_REVISIONS', false );

Note: Be conscious about disabling post revisions. If you lose your internet connection or close your browser, you will lose everything you had written before last saved article. I suggest you enable limit number of WordPress revisions

Source



leave a comment
Please post your comments here.

Search Free SEO Tools

Lastest Analyzed Websites