In this post, I'll show you how to install and configure the WP-Optimize plugin and explain how it will help speed up your WordPress website.
This video is part of my course Essential WordPress Plugins. You can watch the entire course for free here on Envato Tuts+.
How to Use the WP-Optimize Plugin to Speed Up Your Site
First, you need to install the WP-Optimize plugin. Starting in the plugins section of the WordPress admin dashboard, search for
performance, and scroll down to find WP-Optimize. Then click on Install to install the plugin, and click Activate.
The plugin is now activated. To access the settings, go to WP-Optimize in the navigation menu running down the left-hand side.
This takes you to a WP-Optimize admin panel where the settings can be changed according to user requirements. There’s a link to documentation, for further reference, and a link to a premium version that gives extra features. Start by dismissing the information box about WP-Optimize to get to the options.
There are three main settings in which we’re interested when looking at the WP-Optimize plugin. They are:
- Optimise Database
- Image Compression
- Caching Pages
Optimise the Database to Speed Up Your Site
Optimising the database means clearing out anything that is not required in order to help the database run more smoothly.
Because I am already running UpdraftPlus, I can tick this box in order to make a backup of the site before conducting any changes. It’s a good idea to back up a WordPress site before optimising the database because if something were to go wrong, the website would break. If something does go wrong, this means that the backup can be restored to regain the full functionality of the website.
The default settings are:
- Clean all post revisions—each revision to a post creates another entry in the wp-posts table, but you can delete old revisions to save space.
- Clean all auto-draft posts—this is where WordPress creates an automatic draft post. Often these are created and never used, but they still go in the database!
- Clean all trashed posts—does what it says, removes all posts that have been marked as trash, thereby cleaning more data out of the database.
- Remove spam and trashed comments—again, does what it says, thereby clearing the database of useless information.
- Remove unapproved comments—to keep the database as lean as possible and save the need for this to be done manually in the WordPress admin back-end.
Then there are a number of settings to remove expired transient options, remove pingbacks, remove trackbacks, clean post metadata, clean comment metadata, and to clean orphaned relationship data.
In this example, there’s not yet any data to be cleaned up by the plugin.
If you use post revisions, perhaps reverting to previous revisions of a post, or if you find that particular function useful, it may be wise to untick this option.
This is particularly important if more than one person has access to the content. Perhaps, for example, the client has access and screws something up—then the post revision function would save them by easily reverting to an older revision of that post.
When you’re happy with the selections made, click Run Selected Optimizations.
If you now review the options, you’ll see that there are no longer any items like post revisions or comments to be optimised.
By clicking on the Tables tab at the top, it's possible to look at all of the database tables. It’s possible to remove those tables that belong to plugins that are no longer used.
Ideally, when a plugin is uninstalled (not just deactivated), it is good practice that it removes any custom database tables, though this does not always happen.
This is where the WP-Optimize plugin comes in useful by removing tables that are no longer needed.
Image Compression to Speed Page and Image Loading
By compressing images to the size that is actually needed on the web page, a lot of space can be saved on the server, and you can speed up your site's page load times.
The compression of images can really speed up any website, not just a WordPress site. For example, if you upload an image that is 2,000 pixels wide that is only required to be displayed at 500 pixels wide, then that’ll take longer to load.
WP-Optimize allows uploaded images to be automatically compressed and optimised. It also allows you to adjust the balance between compression and image quality, and it enables the compression of existing uploaded images as well.
There are also options to further optimise images in the premium version of the plugin, such as lazy loading.
Speed Up Your Site by Caching Pages
If your hosting provider already provides caching in the hosting plan, then you should not enable this setting. By default, it's turned off.
If enabled, the caching ensures that every time a page is loaded, it's converted to plain HTML. Each subsequent time that page is requested, it loads the HTML page, which is quicker than serving dynamic pages from WordPress.
Options within this section allow for separate files for mobile devices, how long to cache pages for, and an option to purge the entire cache if required.
Normal caching means that if a page is visited, a cached page is created for subsequent visits. Preloading means that the plugin visits every page on the site and generates a preloaded HTML version and stores it in the cache.
Advanced settings allow for exclusions such as pages with required dynamic processes. GZip compression is enabled by default and contributes to page loading speeds.
Other Optimization Settings
This section enables you to schedule cleanups, save log files, and change the settings with discussions, trackbacks, and comments. This may help to speed up the site a little bit as particular posts aren’t going out looking for trackbacks.
WP-Optimize not only makes the optimisation of a WordPress site easy, but also enables the scheduling and automation of ongoing optimisation to keep the site running smoothly.
The Best WordPress Themes and Plugins on Envato Market
Explore thousands of the best WordPress themes ever created on ThemeForest and leading WordPress plugins on CodeCanyon. Purchase these high-quality WordPress themes and plugins and improve your website experience for you and your visitors.
Here are a few of the best-selling and up-and-coming WordPress themes and plugins available for 2020.
- 29 Best Portfolio WordPress Themes for CreativesBrenda Barron19 Jan 2022
- 21 Best WordPress Slider & Carousel Plugins of 2023Daniel Strongin01 Jun 2022
- 29 Best WordPress Calendar Plugins and Widgets (With 4 Free Plugins)Daniel Strongin23 Jul 2022
- 31+ Best Responsive WordPress Themes (For Sites in 2022)Brenda Barron19 Jan 2022
- 30 Best WPBakery Page Builder (Visual Composer) Addons and Extensions of 2023Daniel Strongin25 Mar 2023
- 35 Best Coaching & Consulting WordPress Themes for 2023Brenda Barron23 Jun 2023