WordPress requires a database to operate. Databases are used to store posts, pages, links, users info, comments and other important data to allow WordPress to function. It’s crucial that the database hosting WordPress content run smoothly as possible.
If you’ve been blogging for a while, chances are there are stuff stored in the database that WordPress has no use for anymore. These are known as garbage data and deleting them regularly is important.
By design, WordPress will store every post revision in its database. Every little change you make to existing posts or new ones get additional copy stored in the database. Pingbacks and spam comments also add garbage to WordPress database.
It’s important that you regularly remove these data so WordPress function smoothly. There are many tools that will allow you optimize WordPress database. Many of these tools work but one that I’d recommend is WP-Optimize.
WP-Optimize is an excellent plugin that allows you to optimize and clean garbage data from WordPress databases. It compatible with current version of WordPress.
I personally don’t like installing and keeping multiple plugins in WordPress so if you just want to optimize WordPress database after a long period of time, go ahead and install WP-Optimize and optimize WordPress, then remove it.
That’s what I did on my site.
Before you go ahead and installing WP-Optimize, please backup your database. To learn how to backup WordPress databases, read our post on backing up WordPress database.
When you’re done, install WP-Optimize and optimize your database.
To completely disable revisions in WordPress, add this line in the wp-config.php file in the root directory.