WordPress site running slow on HostGator?
You and everything else. HostGator was rated about the 40th host in this Facebook poll and is known for being 1 thing – cheap. Their servers are incredibly slow and you can actually find this out first hand… just run your site through Google Page Speed Insights and check to see if ‘reduce server response time‘ is in your report. If yes, it means your HostGator server is slow.
So while I’ll show you how to improve scores and load times in Pingdom and other speed testing tools, you will inevitability need to switch hosts if you want a faster website. I use SiteGround who was #1 in that poll, my site loads in >1s, and they will migrate you for free. Fast hosting is the #1 thing WordPress recommends in their optimization guide so it’s kind of important. Leave me a comment if you have any questions… I’m glad to help you out.
- Find Out If HostGator Servers Are Slow
- Run Your Site Through Pingdom
- Configure A Cache Plugin
- Minimize Plugins That Consume High Resources
- Lazyload Your Pages
- Resize Large Image (Serve Scaled Images)
- Losslessly Compress Images In Bulk
- Configure Cloudflare With HostGator
- Add AMP (Accelerated Mobile Pages)
- Minimize Redirects
- Upgrade To A Faster WordPress Host
- Have My WordPress Developer Help You
1. Find Out If HostGator’s Servers Are Slow
Run your site through Google Page Speed Insights and see if reduce server response time is in your report. This means your server (on HostGator) is definitely slow. To fix this you will either need to upgrade your WordPress hosting on HostGator or switch to a faster host. A high number of WordPress sites on HostGator have this item so I would definitely check yours…
I don’t mean to be the messenger of bad news but migrating away from HostGator is literally the best thing you can do for your load times. Plus your site won’t go down for no reason (trust me, I’ve been there). I use SiteGround who was rated the #1 host in that poll. Their speed technology is far superior and uses NGINX servers, solid states drives, PHP7 and a stack that makes your site load super fast. Here’s where HostGator was rated about #40 in this poll…
2. Run Your Site Through Pingdom
Google Page Speed Insights is good for seeing if HostGator’s servers are slow, but Pingdom is much better for accuracy and getting specific recommendations about your site speed. Most items can be fixed by installing a cache plugin with Cloudflare, as well as optimizing images.
Hopefully when you’re done, your Pingdom report looks something like this…
3. Install A Cache Plugin
Your cache plugin and hosting are the 2 biggest speed factors in WordPress. This Facebook poll shows the top rated cache plugins which I definitely agree with. I wrote tutorials for all 3:
- The Ideal WP Rocket Settings With Cloudflare + MaxCDN Instructions
- The Ideal WP Fastest Cache Settings With Cloudflare + MaxCDN Instructions
- The Ideal W3 Total Cache Settings With Cloudflare + MaxCDN Instructions
Here’s a test I did in Pingdom…
WP Rocket (.406)
WP Fastest Cache (.527)
W3 Total Cache (.619)
Here’s a glimpse of the WP Rocket settings which are semi-easy to configure…
Here’s a glimpse of the WP Fastest Cache settings which are super easy to configure…
The W3 Total Cache settings are more difficult to configure but I do have a pre-configured zip file you can upload in your W3TC settings under General Settings → Import / Export Settings. I would still view my W3 Total Cache tutorial and see the screenshots + MaxCDN instructions.
MaxCDN’s Content Delivery Network
All 3 plugins have an option to integrate MaxCDN which is $90/year. I suggest signing up for a 30 day free trial. A CDN (content delivery network) hosts your website on multiple servers around the country/world which reduces the geographical distance it takes for your content to reach your visitor. This can reduce your load times by multiple seconds for visitors who (used to be) far away from your 1 origin server. A CDN is also an item in your GTmetrix YSlow tab.
- How To Setup WP Rocket With MaxCDN
- How To Setup WP Fastest Cache With MaxCDN
- How To Setup W3 Total Cache With MaxCDN
4. Minimize Plugins That Consume High Resources
The key is too deactivate/delete plugins you don’t use, only use lightweight plugins, find your slowest plugins use P3, and to turn OFF functionality on plugins that consume a high amount of resources (like Wordfence’s live traffic reports or Broken Link Checker’s ongoing scans).
- Deactivate/delete plugins you don’t use
- Run the P3 Plugin to find your slowest loading plugins
- Replace slow plugins with lightweight plugins
- Turn off ongoing scans and processes by plugins
- Example: disable live traffic reports in Wordfence
- Delete P3 and other plugins you only need at certain times
- Avoid Jetpack and other robust plugins if you only need some functionality
- Retest your site in P3 if you add a new plugin to see it’s impact on your load time
5. Lazyload Your Pages
Lazyload delays the loading of photos, videos, and iframes so they only load once you scroll down the page and see them. This significantly reduces the initial load time but some people may find the ongoing loading annoying. I suggest trying it out and if you don’t mind it, keep it.
WP Rocket (the cache plugin I recommend) has an option for this in the basic options…
6. Resize Large Image (Serve Scaled Images)
You will find the “serve scaled images” item in your GTmetrix report which just means you need to resize large images to be smaller. GTmetrix will tell you which images need to be resized (and their correct dimensions) but ONLY for that page. That’s why I would start by fixing images that appear on multiple pages (like your logo, sidebar, and footer images) then run your most important pages through GTmetrix and optimize individual images on those.
Once you find oversized images in GTmetrix, resize them, reupload them, and replace the old images with the new ones. In the future it’s best to resize images to the correct dimensions BEFORE uploading them, which is why an “image dimension cheat sheet” can be very handy.
7. Losslessly Compress Images In Bulk
This is the “optimize images” item in GTmetrix. Imagify and Kraken are the best plugins for this… which are both are free until you hit a monthly limit. Other completely free plugins (with no limit) usually have bugs and can break images or just won’t do anything (trust me, I’ve done my research). Avoid plugins like WP Smush.it and EWWW Image Optimizer even if means paying for a $5 Imagify plan or waiting month-to-month for your 25MB Imagify limit to reset.
- Sign up for Imagify
- Install the Imagify plugin
- Paste your API key into the plugin
- Set your compression level (normal, aggressive, ultra), I use aggressive
- Go to media → bulk optimization and Imagif’em all
- If you reach the limit, pay $5 for a plan or wait until next month for it to reset
8. Configure Cloudflare With HostGator
Cloudflare is free and improves your website speed, security, and even your spam protection. Unfortunately you will need private nameservers on HostGator to do this which is only available on their reseller account, VPS, and dedicated server. I have no idea why they do this.
1. Sign up for Cloudflare, add your website, run the scan…
2. Click ‘continue setup’ then scroll down and click ‘continue.’ Choose ‘free website’ then continue again. Cloudflare will provide you with 2 nameservers…
3. HostGator says you will need to contact them to setup private nameservers…
4. Once they do, find them and enter the nameservers provided by Cloudflare…
5. Save it, go back to Cloudflare, then click “I’ve added all missing records, continue”…
6. Still in Cloudflare, go to the speed setting and use these…
6. Go to Cloudflare’s caching settings and Purge Individual Files → Purge Everything.
All done! It can take up to 72 hours for Cloudflare nameservers to propagate.
9. Add AMP (Accelerated Mobile Pages)
AMP Pages make your mobile pages load faster and adds an AMP stamp next to your mobile snippets. This is easy to do (it’s done through a plugin) but it will change the design of your mobile pages. You will basically use the AMP plugin to add the actual mobile pages, then the Glue for Yoast SEO & AMP plugin to customize the color of those new mobile AMP pages.
How To Add AMP Pages To WordPress
- Install the AMP plugin
- Install the Glue for Yoast SEO & AMP (if using Yoast)
- Add /amp/ to any page to see your new AMP pages
- Use the Glue for Yoast to customize the design of these pages
- Wait a few days for Google to update your mobile snippets
- Use Google Search Console’s AMP section to test for errors
10. Minimize Redirects
Means you changed the WWW or HTTP version of your site, but your links/images are still using the old version. You need to correct ALL these which can be done in bulk using the Better Search Replace plugin. Pingdom will only show you errors for that page, so test a few pages out in Pingdom to make sure you took care of all redirects throughout your website.
11. Upgrade To A Faster WordPress Host
Remember this Facebook poll, and remember the reduce server response time item that might have shown up in your Google Page Speed Insights Report, and how fast hosting is the #1 thing WordPress recommends in their optimization guide? It might be time to switch is all I’m saying.
SiteGround was rated #1 in the poll and is who I use…
Average load time on SiteGround is 1.3s…
Other people say the same thing…
Here’s where fast hosting was listed as the #1 thing WordPress recommends in their optimization guide. As long as you’re on HostGator’s slow servers, your site will be slow.
If you look into SiteGround, be sure to check out their features page where you can see a side-by-side comparison of their shared hosting plans (StartUp vs. GrowBig vs. GoGeek). The main difference is GrowBig and GoGeek can host unlimited websites, comes with priority support, and includes more server resources (makes your site load faster). If you view the features page and scroll down to “we allocate the resources you need” you’ll find this under the ‘server’ tab…
12. Have My WordPress Developer Help You
Pronaya is a WordPress developer I found on freelancer.com who specializes in WordPress speed optimization and I’ve been working with him for 5 years. He’s $25/hour from Bangladesh (so there is a time change) and you can email him at email@example.com. He’s optimized my site to load under 1 second in Pingdom and multiple other sites to load 500% faster. He also has a perfect 5 star review on his profile… so if you follow this tutorial and your site is still slow on HostGator’s WordPress hosting, speed projects usually run about $250.
That guide also shows you how to:
- Speed up comments
- Avoid Google Maps
- Specify image dimensions
- Embed light Youtube videos
- Disable trackbacks/pingbacks
- Use a lightweight WordPress theme
- Clean up your database (use WP Rocket)
- Find individual pages that load slow in Google Analytics
I hope you found this tutorial helpful! Retest your site in Pingdom and if your WordPress hosting is still slow on HostGator leave me a comment and I’ll be glad to help. I tried to include everything here but I know it can get technical, so drop me a line if need be. Or if you were able to make your site faster, I would love to hear about your new scores and page load times.