Speed up WordPress, improve Core Web Vitals with Asset Cleanup

Google is on a mission to speed up websites and boost usability. Core Web Vitals is a way of measuring how your site performs for users and is important these days. Asset Cleanup can help.

Unless you have been living on another planet for the past year, you surely will have heard of Core Web Vitals and probably read a lot about it. If you missed it and want to read more about it, view a report on your site in Google Search Console in the sidebar menu. Here is Google’s explanation of Core Web Vitals.

Basically, websites are rewarded for having better CWV. All other things being equal, they will rank higher in search results than another site that has worse CWV. It will not be a big factor and all other things are not usually equal. Content will always have a bigger effect than CWV.

Actually speeding up your WordPress website and improving its Core Web Vitals is not easy. One problem is that boosting performance is not a single thing, but the result of many actions. Some things speed up the site a little and some a lot. I always recommend optimizing images first, because they are the single biggest cause of a slow website. It is low-hanging fruit and fewer, smaller images will result in a better Core Web Vitals report.

Asset CleanUp

Assuming you have done the basics, but still need to improve your site, what more can be done. Asset CleanUp: Page Speed Booster is a great WordPress plugin that can help increase performance and make the site better for visitors, which is exactly what is needed.

Just remember that this is not the complete solution and is just one of the many things you need to to.

Click Plugins in the WordPress sidebar and then click the Add New button at the top of the page. Enter ‘asset cleanup’ into the search box and then install and activate the Asset CleanUp plugin. Notice that it has an almost perfect score. People love this plugin.

Asset CleanUp appears in the sidebar and if you browse through the sections it looks scary! At first sight it is overwhelming and complicated. There is a lot of information and help in the plugin, so spend some time reading through it.

Asset CleanUp WordPress plugin test mode
Test changes in Test Mode, which only admins can see

The first thing you should do is go to Asset CleanUp > Settings > Test Mode and enable it. This means it is disabled for visitors and enabled only for admins – you. If changes are made, visitors will not see them until Test Mode is switched off so you can make sure they work OK.

This is an advanced plugin with features that could break your site, so be careful what you enable. Here I look at the simplest features and the safest to implement.

HTML Source CleanUp

Select the HTML Source CleanUp tab and there are lots of switches that enable you to remove unused items in WordPress code. There is a description next to each one that you should read carefully.

Asset CleanUp plugin for WordPress
The more you remove, the faster WordPress will be

There is nothing here that is vital to WordPress, but the first item, Remove “Really Simple Discovery (RSD)” link tag, is probably the only one you want to keep. It’s a link to your site’s RSS feed, which may be useful.

Each item disabled by turning on the switch improves your site performance a little.

Site Wide Common Unloads

There are a couple of items you can remove here by turning on the switches. If Disable Emojis Site-Wide switch is enabled, you will not be able to use emojis on your site. Do you have emojis on your site? Probably not, so disabling them will not affect you. It will speed up the site though.

Another option here is to Disable Dashicons if Toolbar is hidden (Site-Wide). You, as administrator, see a WordPress toolbar at the top of the page and it has icons. Visitors do not see the toolbar and therefore do not need them. Disabling them for visitors speeds up your site.

Google Fonts

Fonts used on websites are often part of the Google Fonts collection and they are essential to the look and design. However, there is a slow way and a quick way to load them. Your site can ask for Font1 and then ask for Font2 and then ask for Font3. That is slow and multiple requests can be combined into one, so your site basically asks for Font1+Font2+Font3 in one request. This is quicker and the end result is the same.

Select the Google Fonts tab and turn on the switch at the top, Combine Multiple Requests Into Fewer Ones.

Disable XML-RPC

Select this tab in Asset CleanUp settings and there are three options: Keep it enabled, Disable XML-RPC Pingback Only, and Disable XML-RPC Completely. What does all this mean?

Jetpack WordPress plugin and the WordPress app for phones use this feature, so leave it alone if you have them. If you do not use them, and a lot of people don’t, disable XML-RPC for extra speed and security.

Disable plugins except when you need them

Plugins enable extra features in WordPress and they do so by inserting code into the site’s pages. Often, a plugin will insert code into every page, whether you are using the plugin or not. This means that unused code is being loaded, which is simply a waste of time. Remove it and the site will be faster.

A good example of this is the Contact Form 7 plugin. A Contact page is common in websites and usually there is a form for the visitor to fill in that sends you an email. It is quick and easy for the visitor, so it is good to have.

Code for Contact Form 7 is loaded on every page and post on a website, even if the only page that has a form is the Contact page. It is complete a waste of time and the site would perform better if the code was only loaded on pages that use the plugin, like the Contact page.

I am using Contact Form 7 because it is a simple example and many other plugins do this. It is just the way WordPress works.

Go to Posts and open an already published post. Give it a few seconds to sort itself out and then scroll down to the bottom of the post editor. There is a new Asset CleanUp section that shows everything that loads with this post.

Asset CleanUp WordPress plugin settings
Unload on posts, but leave on pages

It enables you to create rules and since Contact Form 7 only appears on the Contact page, it can be automatically unloaded on all pages of ‘post’ type by selecting the option. Save the updated post and the new setting is applied site-wide.

Asset CleanUp WordPress plugin settings
Unload this plugin everywhere, except on this page

Another way to do this is to open the Contact page for editing, scroll down to the bottom and this time in the Contact For 7 section, select Unload side-wide * everywhere. Then also make an exception by selecting On this page. This means the Contact Form 7 code is only loaded on the Contact page.

It is not just about Contact Form 7. I have a similar thing on this website and the forums only appear on pages, so I can unload the forum code for posts, speeding them up.

Asset CleanUp WordPress plugin settings
See all your site-wide rules

Go to Asset Clean-up in the sidebar and select Bulk Changes. Here you can see the rules that have been created and there are options to remove them if necessary.

Removing plugins from pages and posts that do not need them provides a useful performance boost for your site.

Summing up

This has been a very brief introduction to Asset CleanUp and the plugin does a lot more. However, parts of it are very complicated and should not be used unless you are an expert. Always use Test Mode to test the changes – browse a few pages on your site. Don’t forget to turn off Test Mode to make the changes live for visitors too.

There is a reset option if you get in a muddle. Go to Asset CleanUp > Tools > Reset.

Don’t expect massive changes to Core Web Vitals or the site speed. This is just one of many things you need to do to improve your site. Keep it simple and avoid changing settings you don’t understand.

Related articles:

Photo by Nubelson Fernandes on Unsplash.

Leave a Reply