How to Turn Off Post Revisions
The post revisions feature in WordPress can be helpful. It has saved me countless times when I’ve accidentally deleted a chunk of text or inadvertently swiped back and forth on my Mac’s trackpad.
But despite the feature’s helpfulness, most WordPress users don’t actually use it.
Database entries are created for revisions, even if they are not used. These entries don’t really impact your server’s performance, but there are many people out there who wouldn’t miss post revisions if it was no longer available.
In today’s Weekend WordPress Project, I’m going to show you how you can turn off post revisions.
Disabling Post Revisions
If you don’t use post revisions on your website, you can turn them off by placing this code in your wp-config.php file:
define( 'WP_POST_REVISIONS', FALSE );
Limiting Post Revisions
If you would rather limit the number of post revisions that appear in your post editor rather than disable them, you can do that, too.
Just add this code to your wp-config.php file instead:
define( 'WP_POST_REVISIONS', 5 );
This snippet will limit revisions to five. This is especially helpful for users who use post revisions, but don’t want to keep dozens of revisions for posts that receive many edits.Tags: