WordPress Speed Optimization
In WordPress Speed: The Ultimate Guide I will show you how to optimize your slow WordPress website and dramatically improve page load times.
Quick Fix for a Slow WordPress Site
If you’re looking to just make a quick fix the easiest way to improve your site’s speed is with great web hosting.
Consequently one of the best, and quite affordable, options on the market is SiteGround.
I’ll get into more details on hosting in step 2 of this guide.
So you make the decision to run WordPress on your website.
You install in onto your web host.
Type your domain name into your favorite browser to try it out.
…you’re horrified at how incredibly slow each page of your WordPress website loads!
The next thing you know you’re Googling Why is WordPress so slow?
Well you’re in luck!
Because you’ve found my Ultimate Guide to WordPress Speed Optimization post.
I’ve done countless hours of testing on WordPress to figure out how to achieve it’s maximum performance.
And now I’m sharing it all with you here!
WordPress Speed: The Ultimate Guide
1. Speed Testing
A. PageSpeed Insights
A. Shared Hosting – SiteGround
B. Managed Hosting – WP Engine
3. PHP – Latest Version
4. Framework – Genesis
5. Theme – StudioPress
7. Gzip Compression – Enable
8. Cache – WP Rocket
A. WP Rocket
B. Fast Velocity Minify
10. Plugins – Reduce
11. Images – Compress
A. Online – Optimizilla
B. Plugin – ShortPixel
C. Local Machine
12. Leverage Browser Caching
A. WP Rocket
B. SG Optimizer
13. Database – Optimize
A. WP Rocket
B. Swift Performance
15. Redirects – Minimize
16. Hotlinking – Prevent – Cloudflare
17. Gravatars – Disable
18. Pingbacks & Trackbacks – Disable
19. Homepage – Light
20. Audio/Video Files – Hosting Service
21. Google Analytics – Offload
1. Speed Testing – the first step to Optimize your Slow WordPress Site!
So you want to optimize the speed of your slow WordPress website.
Before you change anything though you need to baseline the speeds you’re currently getting.
Fortunately there are some fairly popular free tools that do just this.
Therefore I am suggesting four of them.
They have a lot of overlap, especially in the speed testing department.
You’d be surprised though at the difference in the results between them!
That’s why I opt for all four as a means of checks and balances.
Another good reason to use all four of these tools is that some go into much more depth than others with what they tell you.
So when using any of these tools I suggest testing your homepage.
Mainly because that’s the first page people usually see when they visit your site.
Later on in this speed guide I will be getting into more detail about why your homepage is the most important page to optimize on your site!
This tool runs fairly quickly and simply tests your site for speed.
The downside of it is that it can be oddly inconsistent.
I’ve run back to back tests without changing anything on my site and have gotten different scores.
My homepage currently comes in with a 99 score on their mobile test and 100 on their desktop test.
This is my favorite tool of the bunch.
Especially because it’s very consistent with its scores and gives lots of detailed information and suggestions on how to optimize your site to make it nice and snappy.
My homepage currently rates at 100% on their PageSpeed and YSlow Scores with a less than one second page load time.
It’s easy to get obsessed with trying to get the perfect score here.
And it’s not always possible.
For this reason I’d say to just focus on trying to maximize every issue you see and your page speeds will improve dramatically.
This tool can be can slightly inaccurate at times with its assessments.
But it is great for measuring your page speed load time.
My second favorite of the bunch.
Mainly because this tool gives insane amounts of optimization data and is quite consistent with its results.
My homepage currently gets A’s across the board on its testing.
2. Hosting – the best fix for WordPress Speed
Shared hosting is when your website lives on a server that has other websites on it as well.
In other words you are sharing server resources with other site owners.
Because of this it can be very tricky finding a good shared website hosting company.
Luckily for you I am telling you about the best shared hosting company on the market today…
As mentioned above, this is a biggie.
As a matter of fact many people try to cheap out in this area.
Or go with the well known like GoDaddy, HostGator and Bluehost.
But if I tell you there is an even better AND cheaper option would you believe me?
You wouldn’t right?
Well there is!
If you’re just starting to build your website they have the perfect shared server plans to optimize your WordPress site for speed.
I’m currently on their GoGeek Plan.
They deeply discount their prices for first time customers so I suggest buying the three year plan if you can afford it.
Upon renewal their prices are more in line with the actual value you get from their product!
Managed hosting is a higher tiered product than shared.
More resources are dedicated to your website and as the name implies the hosting company has more of a hands on approach with it.
At the top of the managed WordPress hosting food chain is WP Engine!
Because of their easy to use User Portal combined with 24/7 customer support over the phone, via chat and their ticketing system, they are my number one choice in the game for managed WordPress hosting.
Not only are they fast and offer great customer service but they also recently bought the StudioPress family of products which I will be talking more about later in this guide.
Eventually I will be writing an in-depth guide that really digs into this WordPress hosting topic.
3. PHP – stay updated and avoid a Slow WordPress Site
This one is a fairly easy way to make sure your WordPress site is optimized for speed.
PHP has been around and improving since 1994 and is the programming language that WordPress is coded in.
So in order to get the best performance for your WordPress site you want to make sure you’re running the latest version of it.
Amazingly some site hosts don’t support the latest PHP versions until months and sometimes years later!
SiteGround and many other hosts do though.
In conclusion the key takeaway here is to make sure your server is running the latest version of PHP, which at this writing is version 7.3.
4. Framework – behind the scenes fix for WordPress Speed
Next up on the list of must haves to transition your plodding site to the speed of light is a quality framework.
And to that end there are many out there and I’ll leave the in-depth discussion of this topic to a future post.
Personally I’ve tried a few and have come back to Genesis from StudioPress each time.
With this in mind their lightweight, easy to use, optimized for speed, SEO and mobile responsiveness framework is a great and fairly inexpensive one time purchase that will greatly enhance your WordPress site.
But is a Framework Really Necessary?
Now to be fair, you can skip the framework altogether and go right to the theme which I’ll be discussing next.
But remember though, we’re talking about optimizing your slow WordPress site for speed here.
And if you want to do that the best way is with a premium framework, like Genesis.
Consequently this might seem counterintuitive to those who would say don’t you want to keep it simple here?
Simple is my go to strategy when possible.
But in this case simpler is not better since a well made framework actually improves your WordPress installation.
5. Theme – another way to Optimize your WordPress Site
This is where things can get a little confusing.
Because a lot of people aren’t even aware of frameworks no less how they differ from a theme!
Layers of an Onion
At its core you have the WordPress installation.
Then you layer the framework on top of it.
And then you have a theme on top of that.
I stick with the StudioPress family for my choice of theme.
The reason being is I like having the continuity of the StudioPress brand across my site since I know all of their themes are maximized for speed, SEO and mobile responsiveness.
There are many, many themes from different manufacturers that work within the Genesis framework.
With this in mind just make sure to do your research and pick one that is also optimized for speed, SEO and mobile responsiveness.
So even though you can use many themes without a framework, that’s not the case with the ones from StudioPress.
6. CDN – a must have for WordPress Speed
A content delivery network (CDN) is a network of servers that are placed around the globe so they can deliver your website to the end-user via the location closest to them.
Therefore a CDN is a must have these days if you want to optimize your WordPress site for speed!
The image on the left represents a traditional one server setup delivering your content to the web.
And in contrast the image on the right shows how multiple servers (a CDN) would optimize your site’s speed.
In short a CDN is a no brainer if you’re interested in maximizing how fast your slow WordPress site will run.
Furthermore to enhance my site’s speed to another level I use two of them!
It is only necessary to use one though.
Amazingly Cloudflare still offers an incredible free CDN that I’m suggesting everyone go sign up for right now!
The second, paid, CDN option I use is the $10 a month offering from StackPath.
In short it is well worth the price and I highly recommend it for upgrading the speed of your sluggish WordPress site.
7. Gzip Compression – an easy fix for a Fast WordPress Site
This is a fairly simple way to optimize your site.
Gzip compression is the process of reducing the volume of your WordPress files which in turn will enhance it for speed.
Quickly enable Gzip Compression in the .htaccess file on your server or via a plugin.
8. Cache – Optimize your Slow WordPress Site for Speed
This is a biggie and somewhat complicated since there are many ways to do it!
For a deeper explanation of what cache is make sure to check out my What is WordPress Cache? post.
In short caching is when certain website data is stored statically on your web host so your site’s pages load faster.
This is a good thing, especially for sluggish WordPress sites.
There are lots of plugins available to do this.
Many are free and some require payment.
A popular premium caching plugin I use and recommend is WP Rocket.
9. Minify – will Optimize a Slow WordPress Site for even more Speed
This is another fairly complicated to explain but essential optimization method to get your slow WordPress site moving faster.
In essence minification is the process of literally reducing the size of site files by removing all of the white space and other unnecessary characters in them.
Once again there are many plugins available to do this and it can be quite the task to sort through all of the options.
Luckily for you I have already done this!
The paid plugin I use for this task is WP Rocket.
On the positive side it’s part of the same plugin I mentioned earlier in the cache section of this guide.
And they have a “File Optimization” section that handles all of the minification for you.
If you’re interested in a free plugin option to minify I highly recommend Fast Velocity Minify.
Don’t let the free price fool you, it packs quite the punch.
I am always amazed at what it accomplishes during my site tests to improve WordPress speeds!
10. Plugins – too many means a Slow WordPress Site
We all love plugins.
Because they are great to do all those little things we want done on our site.
If you use the wrong plugin, or too many plugins, your WordPress site speeds will dip into the crawling, stagnant, tortoise like regions that no one wants to be in.
I like to use as few plugins as possible.
Right now that ranges from 20-25.
For the most part though I suspect a good amount can be anywhere from 30-40 as long as they are lightweight.
If you’re using more than that I’d seriously assess what each of them are doing and check if they are actually needed.
Remove the bloat to optimize!
One thing you can do is try deactivating all of them and running the above mentioned speed tests.
By doing this it will give you a good idea if your plugins are slowing down your site.
Just remember to also do the speed testing before you deactivate all of them so you have something to compare the results to.
If there is a speed difference with all of the plugins disabled then I suggest turning them on one at a time and rerunning all of the tests each time.
Even though this can be a little time consuming it is well worth it.
In the final analysis when you do this with all of your plugins you will find the culprit that is stealing your speed resources.
Once you isolate the bad plugin ditch it.
With a little research there is always another better one to be found.
11. Images – second biggest cause (behind hosting) of a Slow WordPress Site
This is a big problem for a lot of slow WordPress sites.
Having giant, hi-resolution pictures splashed across your web pages are never a good thing.
As a result your WordPress site will be slow because these large images take time to load.
And the bigger they are, and the more of them there are, the bigger the problem is.
With this is mind it can even be a problem with smaller images that are not compressed.
The solution here, other than removing the unnecessary images altogether, is to compress the images that are on your site.
This can be done in a variety of ways.
The three main methods are online, with software on your local machine, or via a plugin after the images are uploaded into your WordPress Media folder.
There are a bunch of free and paid online services to compress images.
The best one I’ve found so far is Optimizilla.
After I compress my images online I let a plugin do the rest of the work.
There are tons of options out there.
Some really good, and some really bad.
Some free, and some paid for.
In particular the one that I use and highly recommend is ShortPixel Image Optimizer.
Compresses the image on upload.
And on top of that they allow you to compress up to 100 images each month for free.
I used to prefer this method but now realize that desktop software does not even come close to compressing images as well as online services or plugins.
The reason for this I’m guessing is because the desktop software options don’t really make this their main focus.
Anyway here are a few options that will compress images for you.
Adobe’s Photoshop is a paid software option that has a built-in “Save for Web” feature that reduces the size of any image.
IrfanView is a free software option that also has a “Save for Web” feature once you install the additional free plugin for it.
In conclusion if you follow any of the image optimization recommendations above you will be sure to notice improved load times for your slow WordPress site.
12. Leverage Browser Caching – for more WordPress Speed
By doing so you’re reducing the amount of data that needs to be downloaded while navigating through your website.
Favorably for us this is quite an easy fix.
By installing and activating the aforementioned WP Rocket plugin your browser cache will automatically be fully leveraged.
If you’ve opted to go with my SiteGround hosting recommendation then you can also leverage browser caching via their SG Optimizer plugin.
13. Database – cleanup to Optimize WordPress for Speed
This is a behind the scenes improvement.
Basically you’ll be trimming the fat in your database of unneeded tables and entries that could be slowing you down.
This can be done manually but I do not recommend it because it can get complicated fairly quickly.
With this in mind I suggest using a plugin to do the job for you.
Altogether this is a quick, simple and convenient process.
If you’re looking for a free option I highly recommend using Swift Performance Lite
They have a database optimizing solution that rivals the one from WP Rocket.
In fact I actually use both of them to really maximize my database tables and to make sure I avoid a WordPress slowness database issue on my site!
14. Updates – a must have to Optimize WordPress
This is a subtle yet very important item on this list to improve the speed of your slow WordPress website.
Updates are important, not only for speed optimization but even more so for security fixes.
In essence do them, I’ll leave it at that!
Stay on top of the latest WordPress updates.
They seem to come out with updates every month or so these days.
And here you can see the full history of WordPress versions.
Equally important is keeping your plugins updated.
In fact the plugin makers are constantly revising their plugins and these updates will improve your site’s security and performance.
15. Redirects – a subtle way to increase your WordPress Speed
When you set up your WordPress site you will choose the main way you want the URL to display.
For instance on this site I choose http://compvarietyplus.com.
But I could’ve chosen https://www.compvarietyplus.com.
Either one is fine BUT the other version must be setup to redirect correctly.
In order to redirect correctly you only want there to be one jump (redirect) from any URL option to the one you choose.
By happy chance there is a great free tool you can use to check if your redirects are setup correctly called the Redirect Mapper.
If you put my site in there as a test you will see the correct way it should look.
I only have 1 Redirect for three of the URL formats (with and without the SSL) and No Redirect for the main URL format I’ve chosen.
If you have more than 1 Redirect on any of the formats I suggest contacting your web host to help you correct this.
Often times it is a backend issue that needs to be corrected and can be somewhat tricky.
16. Hotlinking – prevent this to avoid a Slow WordPress Site
Hotlinking is when you have an image or video hosted on your website and another website directly links to it from their website.
As a result when someone does this it draws on your site’s bandwidth and will slow your site down.
You want to prevent this by all means.
In Cloudflare’s settings on the “Scrape Shield” tab there’s an option to turn on Hotlink Protection.
17. Gravatars – turn these off to Speedup WordPress
These are the little images that appear next to someone’s name when they make a comment on your site.
Even though they can add character to your site each one of these little images will slow your WordPress site down bigtime.
These can easily be disabled in the “Discussion” section of the WordPress “Settings”.
18. Pingbacks & Trackbacks – disable to prevent a Slow WordPress Site
These are notifications that are sent to a website to notify them that they’ve been linked to.
On balance this can sound useful but in fact it can use up unnecessary server resources.
As with Gravatars, Pingbacks and Trackbacks can easily be disabled in the WordPress settings.
Just navigate to the same “Discussion” section in the WordPress “Settings” to do this.
19. Homepage – keep it light to Optimize WordPress Speed
Your homepage is often the first page people see when they visit your site by typing in your domain name.
If you’re interested in having a fast WordPress website it’s important to maintain a smooth, light, fast running homepage.
By and large even if the rest of the pages on your site are a little slower that’s okay.
If you have caching set up properly, as mentioned above, many items will preload when someone visits your light and optimized homepage, and make the rest of the pages on your site open quicker.
In short this will make for a much better and faster overall user experience when visiting your WordPress site.
20. Audio/Video Files – host elsewhere to avoid a Slow WordPress Site
If you thought images were slowing your site down audio and video files are even worse!
These are often giant sized files that bog down your site’s performance.
So if you are going to have audio or video files on your WordPress site it is imperative that you host these files elsewhere.
There are many services like YouTube, Vimeo and SoundCloud that allow you to upload your content for free.
They then provide you with a link to seamlessly embed the content into your site.
21. Google Analytics – offload for a WordPress Speed Bump
If you’re interested in tracking how many visitors your site has it is essential for Google Analytics to be installed.
Consequently deploying it correctly for WordPress speed optimization can be quite challenging.
In order to work properly the code needs to be embedded into the header or footer of every page.
This can slow your WordPress site down.
And even when done properly it will still kick up warnings on the above mentioned speed tests.
There are many plugins that offer to offload Google Analytics for you.
Some are good, others not so much.
In conclusion I hope you’ve enjoyed my Ultimate Guide to WordPress Speed Optimization.
Make sure to comment below.
Say hello, or add something you think I might have left out to make a Slow WordPress Site Fast.
Thanks for reading!