Have a slow WordPress site?

A slow WordPress website is usually caused by your infrastructure (hosting, page builder, theme, plugins). But it can also be from unoptimized images, fonts, and third party scripts. That’s why you should use tools like GTmetrix to pinpoint the exact reason your site is slow.

This post you’re reading has over 70 images, 480 comments (while showing Gravatars), uses third party fonts from Font Awesome, Elementor page builder, and Google Analytics. Yet, it can still load in about 1.3s with a 2.56MB page size, 89 requests, and 100% + 97% GTmetrix scores.

I’ll show you how to take your GTmetrix + PageSpeed Insights report and make WordPress-specific optimizations that improve grades/load times. I’ve already written popular guides on WP Rocketslow plugins to avoid, and a list of 24+ speed plugins. This combines everything.

When in doubt, look at the WordPress optimization guide to see the most important factors. The most common fixes for a slow WordPress site are usually related to your infrastructure (theme, hosting, page builder, cache plugin, CDN, and plugins you’re using). While optimizing images and third party scripts can definitely speed up WordPress, most factors are site-wide.

For this, I recommend Cloudways or Kinsta (hosting), Astra or Oxygen Builder (theme + page builder), and WP Rocket (main optimization plugin). You will avoid 90% of speed issues and they’re all rated highly in Facebook polls. Comment with your GTmetrix report if you need help.


GTmetrix (load times) should be your primary metric while PageSpeed Insights doesn’t even measure load times. Getting 100% in every single tool is not realistic unless you have a bare bones, static HTML site. Don’t obsess over scores – obsess over your actual load times instead.



1. Use Faster WordPress Hosting

Hosting recommendations are usually garbage.

Join the WordPress Hosting Facebook Group to get unbiased feedback. Most members (myself too) swear by Cloudways WordPress Hosting. Specifically DigitalOcean / Vultr High Frequency.

Yes, it’s a little more expensive at $10-$13/month, but we’re talking about speed here – not being cheap. With Cloudways, you have a choice of using DigitalOcean, Vultr High Frequency, Google Cloud, AWS, or Linode. These are worlds faster than shared hosting and can handle resource-intensive tasks much better (Elementor, Beaver, Divi, WooCommerce, AdSense, etc).

Cloudways makes it easy to test them out and see the difference in your load times: they do free migrations, monthly pricing, a Migrator plugin, and a promo code to save money: OMM25

Here’s what happened when I moved:

SiteGround vs Cloudways

GTmetrix tests are always different, but even posts with a huge page 2.70MB page size and 96 requests can often load in under 2s. I’ll also take a 148ms time to first byte any day of the week.


The evidence is there:

Cloudways Response TimesCloudways-Migration-Result
Cloudways Google PageSpeed
WP Engine To Cloudways
DigitalOcean Pingdom Report
Godaddy DigitalOcean Migration
Cloudways Pingdom Load Times
Cloudways Pingdom Report

This was a simple Pingdom test to measure load times of 16 WordPress hosts. I signed up for popular hosting companies then installed the same Astra Starter Site on each of them while measuring load times in Pingdom for 1 week at 30 minute check intervals. Some domains are still live (cwdoserver.com is hosted on a $10/month Cloudways DO plan and stgrndserver.com is hosted on SiteGround GrowBig). I cancelled most of them because it was getting expensive. Even when browsing through their pages or running your own tests, you can see the difference.


Hosting Companies You Should Avoid

  • SiteGround – they have gone completely downhill in recent years.
  • Bluehost – slow servers, owned by EIG, bad support, rated poorly in FB Groups.
  • HostGator – also owned by EIG with slow servers, bad support, CPU limit issues.
  • GoDaddy – top malware hosting network worldwide, rated poorly in FB groups.
  • Hostinger – they write fake reviews and vote for themselves in Facebook polls.
  • WP Engine – also not what it used to be, expensive and not even fast anymore.
  • *A2 Hosting – if you can’t afford Cloudways, A2 is still fast and uses LiteSpeed.

I use Cloudways because:

  • Even posts with a 2.70MB page size can load in under 2s
  • DigitalOcean and Vultr HF are miles faster than shared hosting.
  • It’s $10-$13/month (no yearly contracts or high renewal prices).
  • Varnish, Redis, and memcached are all built-in for higher performance.
  • You get to pick from DigitalOcean, Vultr HF, Linode, AWS, Google Cloud.
  • 4.8/5 star TrustPilot rating and highly recommended in Facebook Groups.
  • They have 25+ data centers between all their cloud hosting providers.
  • No CPU issues like on SiteGround, Bluehost, and other shared hosting.
  • SSL, staging, and backups are all very easy in the Cloudways dashboard.
  • Support used to be average, but is now really good as reflected on TrustPilot.
  • They offer a free migration but their Migrator plugin will also do the trick.
  • Adding a server, migrating your site, and the dashboard is actually very easy.
  • Mustasaam (their community manager) gave me peace of mind when moving.
  • Only complaint is they need to add LiteSpeed servers to their list of providers.

Affiliate Disclaimer – if you sign up for Cloudways using my affiliate link, I would seriously appreciate it. I don’t recommend bad hosting like many other affiliates. I also donate quite a bit to charity ($6,000 to GoFundMe so far) and your support would really help. I try to base my reviews not only from my experience, but real evidence from the overwhelming feedback in numerous Facebook Groups. It would mean a lot.


Just do your research and look at this Facebook thread.


2. Rethink Your Theme + Page Builder

Most people are using Astra Themes.

The only problem with Astra is that most of their themes use page builders. Even Elementor adds a lot of scripts that can mildly slow down your WordPress site (you can check these in Asset CleanUp or Perfmatters). That was my biggest complaint when I had my site redesigned in Astra (I even went themeless). My StudioPress theme was slightly faster with 0 extra scripts.

It really depends on what you want; if you like Astra + Elementor for designing your site and don’t mind a slight decrease in speed, that’s what I would recommend. If you’re a speed freak like me and only want the fastest stuff, I wish I would have stuck with StudioPress and Genesis.


Here were my extra CSS and JavaScript files added by Elementor:


I recommend either Astra or Oxygen Builder.



3. Configure A Solid Cache Plugin

As far as GTmetrix scores go, your cache plugin has the biggest impact.

WP Rocket is the most popular cache plugin (it’s also what I use) mainly because it comes with more speed optimization features than any other cache plugin. This not only results in better GTmetrix scores, but also means you don’t have to install a bunch of extra plugins on your site.

Get 10% off WP Rocket by signing up for their email list on their coupons page. Then check my recommended WP Rocket settings for optimal GTmetrix scores/load times.

With most other cache plugins, you would need to install about 7 extra plugins to get these features when WP Rocket has them all built-in. Otherwise you will need to research which features your cache plugin comes with, then install these plugins if it doesn’t support them.

  • Database cleanup (built-in to WP Rocket, or use WP-Optimize)
  • Heartbeat control (built-in to WP Rocket, or use Heartbeat Control)
  • Lazy load images/videos (built-in to WP Rocket, or use WP YouTube Lyte)
  • Optimize Google Fonts (built-in to WP Rocket, or use OMGF, or SHGF)
  • Host Google Analytics locally (built-in to WP Rocket, or use Flying Analytics)
  • Prefetch DNS requests (built-in to WP Rocket, or use Pre* Party Resource Hints)
  • Integration with Cloudflare + other CDNs (built-in to WP Rocket, or use CDN Enabler)

2016 best cache plugin poll

2019 cache plugin poll

Swift vs WP Rocket

2016 cache plugin poll

Best cache plugins 2018 poll

wp rocket vs w3 totla cache

What About SG Optimizer? If you’re on SiteGround, use their SG Optimizer plugin (instead of WP Rocket) with these SG Optimizer settings. It’s free and comparable to WP Rocket (you will still need heartbeat control and database cleanup). This plugin is only for SiteGround’s hosting.

WP Engine + GoDaddy – these hosts have their own built-in caching system and blacklist you from using cache plugins. In this case, use Autoptimize to optimize HTML, CSS, and JavaScript.

I also have configuration tutorials for WP Fastest CacheW3 Total CacheWP Super Cache, and Swift Performance, but I definitely recommend WP Rocket as your one and only caching plugin.


4. Upgrade To PHP 7.4

Login to your hosting account (or use the Display PHP Version plugin) to see which PHP version you’re currently running. WordPress stats show most users are running outdated PHP versions when PHP 7.4 is available on many hosting accounts. Upgrading is as simple as finding the PHP Version Manager (or similar) in your hosting account, then upgrading the latest version of PHP.


Some hosts are quick to release new versions (SiteGround, Cloudways, Kinsta), while others don’t make an effort to stay current in technology. Another reason to avoid EIG and GoDaddy.

*Check your website for visible errors since non-maintained plugins may not be compatible. If you do see errors, you can always revert back to an earlier PHP version.


5. Enable Varnish + Memcached

Many cloud hosting providers support Varnish + Memcached. Login to your hosting account and activate them. If you’re using Varnish, be sure to enable the Varnish addon in WP Rocket.



6. Use A CDN

Most people use Cloudflare or RocketCDN (from WP Rocket).

RocketCDN uses StackPath’s data centers and offers it at a lower price than if you buy directly from StackPath. Both are great CDNs, but there are a few major differences between the two.

Cloudflare vs. RocketCDN

  • Cloudflare is free, RocketCDN is $6.99/month
  • Cloudflare cannot serve images from their CDN, StackPath can
  • Cloudflare has 200+ data centers, StackPath has 45 data centers
  • Cloudlare’s data centers are likely not as high-performance as StackPath
  • Cloudflare has a dashboard you can login to and tweak, RocketCDN does not
  • Cloudflare’s dashboard has extra features like page rules, Rocket Loader, Railgun
  • Cloudflare requires changing nameservers (some hosts also have an option to activate Cloudflare directly from your account), StackPath’s set up is automatic with WP Rocket


Ensure Cloudflare Compatibility With WP Rocket – WP Rocket and most other cache plugins ask for your Cloudflare Zone ID, Global API Key, and your Cloudflare account email. Add them.


Configuring The Cloudflare Dashboard – if you’re using Cloudflare, login to your dashboard. There are a few things in here that aren’t available if you set up Cloudflare through your host.

Page Rule 1: Cache Everything And Force HTTPS – cache your website aggressively.



Page Rule 2: Secure The WordPress Admin And Bypass Cache – sets security level of the admin to high and bypasses Cloudflare’s cache in the admin, since you don’t want CDNs (or apps + performance features like Rocket Loader) running inside the admin.



Page Rule 3: Decrease Bandwidth Of WP Uploads – since the content in your WP Uploads folder does not change frequently, increasing Edge Cache TTL to a month can save on bandwidth, since the WP Uploads folder cache won’t be refreshed as often.



Setting Up RocketCDN Or StackPath – the easiest way to set up RocketCDN is with WP Rocket. If not using WP Rocket, you will need to sign up for a StackPath account through their website then follow instructions for creating a CDN site. They will assign you a CDN URL which most cache plugins (including Autoptimize) have a field for. Or use the CDN Enabler plugin.

Make Sure Your CDN Is Working – every CDN should show 100% in GTmetrix YSlow except Cloudflare’s CDN. To make GTmetrix detects Cloudflare, you’ll need to sign up for a GTmetrix account → User settings → “add your hostname to YSlow CDN Hostnames.” You can also use Cloudflare’s Claire Chrome Extension to see if it’s working. GTmetrix always detects StackPath.

CDN GTmetrix YSlow


7. Avoid 65+ Slow Plugins

You can find your slowest plugins in the GTmetrix Waterfall tab or Query Monitor.

Slow WordPress Plugin


Most slow WordPress plugins include social sharing, statistic (analytics), sliders, portfolios, page builders, calendars, chat, contact forms, related post, sitemap, Wordfence, WPML, WooCommerce, and any plugin that runs ongoing scans or processes. These can be identified using Query Monitor or GTmetrix Waterfall.

  1. AddThis
  2. AdSense Click Fraud Monitoring
  3. All-In-One Event Calendar
  4. Backup Buddy
  5. Beaver Builder
  6. Better WordPress Google XML Sitemaps
  7. Broken Link Checker
  8. Constant Contact for WordPress
  9. Contact Form 7
  10. Contextual Related Posts
  11. Digi Auto Links
  12. Disqus Comment System
  13. Divi Builder
  14. Elementor
  15. View Full List Of 65 Slow Plugins


Lightweight Plugin Alternatives


8. Optimize Third Party Scripts

Third party scripts are anything that create requests from external websites.

These include Google Fonts, Analytics, Maps, AdSense, Tag Manager, embedded videos, social media widgets, Facebook Pixel, Gravatars, or even like buttons from your social sharing plugin. Some can be optimized to have no impact on GTmetrix while AdSense/Tag Manager are harder.

The next sections (7-16) show you how to optimize specific third party scripts that may be giving you errors in your GTmetrix and Google PageSpeed Insights reports.

Step 1: Learn Which Third Party Scripts Are Slowing Down Your Site
Look at reduce DNS lookups in GTmetrix YSlow or third party usage in PageSpeed Insights.


Common third party domains taken from Github:


Step 2: Add Domains To Prefetching
Take the external scripts from your GTmetrix report and add them to WP Rocket (Preload → Prefetch DNS Requests). Prefetching and other browser resource hints makes them load faster. If you don’t have WP Rocket, you can do this with Perfmatters or Pre* Party Resources Hints.


Step 3: Use Flying Scripts To Delay Loading Them
The Flying Scripts plugin delays loading JavaScript until the timeout period you set in the plugin. It’s the only plugin that let me show Gravatars without them impacting my GTmetrix report, but this can also be done with other third party scripts. Just enter the keyword of the script into the plugin (eg. discuz) and set a timeout period. I also recommend checking out Gijo’s speed plugins.


Don’t forget to see the next few sections which will help you better optimize external scripts.


9. Google Fonts

Here are 4 steps for optimizing Google Fonts and Font Awesome.

Optimize Fonts With WP Rocket Or SG Optimizer – both WP Rocket and SG Optimizer have an option to optimize Google Fonts. This combines your fonts to create fewer HTTP requests.


Host Google Fonts Locally – use the OMGF plugin to host fonts locally. The plugin will automatically download your fonts, create a stylesheet for them, then include it in the header.

Preload Fonts – grab the URLs of your font files in the GTmetrix Waterfall report and add them to WP Rocket’s “preload fonts” option, or in OMGF. This helps browsers download fonts faster.


Be Minimal With Fonts + Weights – be minimal with the number of fonts and weights.


10. Google Analytics

Hosting Google Analytics locally will fix the leverage browser caching issue for Google Analytics in GTmetrix. For this, I use the Flying Analytics plugin since WP Rocket’s Google Tracking add-on still showed errors. Insert your Google Analytics Tracking ID (the UA code) into the plugin, then use the “Minimal Analytics Inlined” method which only adds a measly 1.4KB.



Plugins to host Analytics locallyWP RocketPerfmattersFlying AnalyticsCAOS.



11. Google AdSense

Google Adsense is one of the most difficult scripts to optimize and you shouldn’t expect a good GTmetrix report with it. You can try enabling Cloudflare’s Rocket Loader which defers loading of JavaScript until after rendering, but affiliate links are way faster and usually more profitable.


12. Google Tag Manager

GTM should usually only be used for large, unoptimized sites.

If you absolutely need it, use a good Google Tag Manager plugin and be minimal with tags, but that’s about all you can do. I don’t use GTM on my website (my load times are more important).

Google Tag Manager Speed


13. Comments + Gravatars

I use 3 plugins for comments which you’ll see zero errors for in GTmetrix.

  • wpDiscuz: commenting plugin.
  • Flying Scripts: delays loading of Gravatars.
  • WP User Avatar: use a custom, optimized photo as the default avatar.

Step 1: Configure wpDiscuz to load faster.

Comment thread displaying → initiate AJAX loading after page and lazy load comment.


General → disable “use WordPress native AJAX functions” and enable combine/minify JS/CSS.


Styles and colors → disable “load font awesome CSS lib.”


Step 2: Delay Gravatar loading with the Flying Scripts plugin.


Step 3: Upload a custom, optimized photo using WP User Avatar.


Retest your GTmetrix report and your comments should load much faster with no errors.


14. Facebook Pixel

Use the Pixel Caffeine plugin and host Facebook Pixel locally in WP Rocket.



15. Use A Fast Social Sharing Plugin

WP Rocket did a test on the fastest social sharing plugins.

The Grow by Mediavine plugin (Social Pug) was rated the #1 fastest social sharing plugin. It’s also what I use and saw no difference in my GTmetrix report. You can see a preview near my comments section; the buttons look nice, can be loaded before and after the content, and has options for Facebook, Twitter, Pinterest, LinkedIn, email, print. You can also do a floating bar.


16. Optimize Images + Videos

There are several ways to optimize images. The first 3 items are in GTmetrix, the last 2 are from PageSpeed Insights. Speed testing tools only show you unoptimized images for the single page you test (keep that in mind when fixing serve scaled image or specify image dimension errors).

  • Serve scaled images – resize large images to be smaller.
  • Specify image dimensions – add a width/height to the image’s HTML.
  • Lossless compress – use an image optimization plugin to compress images.
  • Lazy load images + videos – delays load of images/videos until they’re visibly seen.
  • Serve images using next-gen formats – use WebP/SVG format instead of JPEG/PNG.


Serve Scaled Images – resize large images to be smaller. GTmetrix tells you the correct dimensions. Just click the image in GTmetrix, resize it to the new dimensions, and replace it. Never use the ‘drag to resize’ feature in the visual editor since this only resizes the displayed image (not the actual image). It’s best to resize to the correct dimensions before uploading it.


Create a cheat sheet so you can use the correct dimensions before uploading images:

  • Slider images: 1903(w) x 400(h)
  • Carousel images: 115(h)
  • Widget images: 414(w)
  • Full width blog post images: 680(w)
  • Featured images: 250(w) x 250(h)

Specify Image Dimensions – means you need to add a width + height in the image’s HTML or CSS. This usually only happens for hand-coded HTML and plugins that don’t take care of this for you. Get the image dimensions from GTmetrix, locate the image, then add the width and height.


Optimize Images – losslessly compress images (also known as “optimize images” in GTmetrix). The best way to compress images is when you’re editing them (eg. in Photoshop or GIMP) since you will likely see a loss in quality with image optimization plugins, even if you select “lossless compression” in the settings. Otherwise, ShortPixel or Imagify are decent options. These plugins can also be resource-intensive and slow down your WordPress website temporarily.

Lazy Load Images + Videos – in your WP Rocket Media settings, enable lazy loading of images, videos, and replace the YouTube iframe with a preview image. These will make images and embedded videos load significantly faster, as they’re often the heaviest element on a page. If you’re not using WP Rocket, try A3 Lazy Load (for images) and WP YouTube Lyte (for videos).


Serve Images In Next-Gen Formats – most image optimization plugins have an option to convert images to WebP format, or the WebP Converter For Media plugin has great ratings.



17. Reduce Server Response Times

I want to clarify a few things about server response times.

Most hosting providers let you monitor CPU and RAM (memory usage). If you notice these are very close to exceeding your limits, this will put stress on your server. The whole goal is to make your server “relaxed” by giving it enough server resources to accommodate your site’s resource consumption (from high CPU plugins, traffic, WooCommerce, etc). If you notice you’re almost hitting your limits or exceeding them and getting 503 errors, it means your server is stressed.


That’s why it’s so important to look at how many server resources come with your hosting plan. Any host that says “unlimited bandwidth” is lying (just check their terms and conditions page and they will mention their CPU limits). Especially if you anticipate high resource consumption, make sure your hosting plan includes enough resources to properly accommodate your site.



18. Clean Your Database

Use WP Rocket or WP Optimize to clean your database.

Ongoing cleanups keep your database optimized and removes transients, spam + trash comments, and potentially hundreds of post revisions which WordPress stores automatically every time you update content. Unless you need post revisions to restore backups of old content, you should be able to delete everything. I recommend scheduling weekly cleanups.


Delete Old Plugin Tables – one thing I like about WP-Optimize is the option to delete database tables left behind by old plugins that aren’t installed anymore (these are often pre-configured settings). If you don’t plan on using these plugins again, delete the tables that say “not installed.”



19. Remove Bloat

Perfmatters (by Kinsta) is the ultimate bloat removal plugin.

The features page includes descriptions of what each item does, but it removes unnecessary WordPress features which you probably don’t need. It even has options for optimizing your Google Analytics tracking code, WooCommerce, prefetch + preconnect, and heartbeat control. Remember to selectively disable plugins in the Perfmatters script manager or Asset CleanUp!


Limit Post Revisions – use Perfmatters or add the code to your wp-config file.

define('WP_POST_REVISIONS', 5);

Increase Autosave Interval – use Perfmatters or add the code to your wp-config.php file.

define('AUTOSAVE_INTERVAL', 60);

Disable Trackbacks + Pingbacks – use Perfmatters or disable in Settings → Discussion.


Disable Unused Addons + Modules – if you’re using a plugin containing a bunch of addons or modules (Elementor, Ultimate/Premium Addons, JetPack), delete the ones you’re not using.


Delete Unused Plugins + Themes – any plugins/themes you’re not using should be deleted.

Delete Unused WordPress Themes


20. Disable Plugin Usage Tracking

Any time you have an option to disable usage tracking, do it. Sorry plugin developers.

I also don’t recommend Yoast’s speed indexing (the comments have horrible reviews).



21. Disable Plugins On Specific Pages + Posts

The Perfmatters script manager (premium) and Asset CleanUp (free) both let you disable plugins/scripts from running on specific pages/posts. Some plugins load across your entire site (even on content they’re not being used on), so it’s best to disable them when that’s the case.


  • Disable slider plugin on pages that don’t use sliders
  • Disable rich snippets plugin on pages that don’t use rich snippets
  • Disable contact form plugin on pages that don’t have a contact form
  • Disable affiliate link management plugin on pages that don’t use aff links
  • Disable social sharing plugin on all pages (since it’s usually for blog posts)


Perfmatters and Asset CleanUp (the premium version) have a Regex option that allows you disable plugins/scripts based on specific URL patterns and categories. For example, you may want to only enable your schema plugin on posts containing the word “review” in the URL.


22. Minimize Redirects

If you have URL redirect errors in GTmetrix, it usually means you changed the WWW or HTTP(S) version of your website but didn’t change all your links and images to reflect the new version. In this case, try using the Better Search & Replace plugin to fix these errors in bulk.

minimize redirects

Third party scripts and poorly coded plugins can also cause redirect errors in GTmetrix. The solution completely depends on which plugins and third party scripts you’re using on the site.


23. Don’t Enable Yoast Indexables

Yoast 14.0 came out with indexables which they claim “can provide a speed boost of 5-10%.”

However, if you look at the comments, it’s clear they have not thoroughly tested this (many complaints about CPU spikes, crashed websites, errors, etc). None of the feedback looks positive, so I would at least hold off of clicking that button until they do more thorough testing.



24. Utilize Plugins By Gijo Varghese

Gijo Varghese has create quite a few plugins for speeding up WordPress.

These plugins help you host Google Analytics locally, optimize images and serve them from a CDN, preload pages, delay loading scripts by creating a timeout, and ensure text remains visible while loading fonts. All have great ratings. Check out his WP Speed Matters Facebook Group.



25. Increase Memory Limit To 256MB

WooCommerce and WPML require a 256MB memory limit, but you should really be using 256MB no matter which type of WordPress site you’re running. Some hosts have an option to increase it in their dashboard, otherwise edit your wp-config.php file and add the code below.


define('WP_MEMORY_LIMIT', '256M');


26. Make WooCommerce Load Faster

WooCommerce sites run extra scripts, styles, cart fragments, and they usually require more plugins. That’s why when choosing a hosting plan, you should usually buy one tier up of what you actually need to accomodate for the extra resources often required for WooCommerce.

WooCommerce Cart Fragments

Optimize WooCommerce Scripts, Styles, Cart Fragments
To optimize these, use Perfmatters or there are quite a few solutions on Github and WooCommerceDisabling scripts will disable WooCommerce scripts and styles everywhere except on product, cart, and checkout pages. There’s also an option to disable cart fragments.

perfmatters woocommerce optimization

Clear WooCommerce Transients
If you feel like your WooCommerce website is getting sluggish, go to WooCommerce Status settings → delete all transients. Transients temporarily store cached data in your database.

Delete WooCommerce Transients


27. Block Bad Bots From Using Resources

You would never know if spam bots are hitting your site unless you checked your Wordfence live traffic report. By blocking them, you will save resources and put less stress on your server.

Step 1: Install Wordfence (you’ll want to uninstall it when you’re done).

Step 2: View your live traffic report (under Wordfence’s Tools settings) which shows you all bots hitting your website in real-time. Googlebot is obviously OK, but when I did this, I saw compute.amazonaws.com making a ridiculous amount of requests every couple seconds. I Googled it and sure enough, this was a bot known for sucking up bandwidth. View your report for a minute or two and see if bots with sketchy names are constantly hitting your site. If you have doubts, Google their hostnames and see if other people are having issues with that bot.


Step 3: Block the bots. You have a few options: Wordfence blocking (however the plugin itself consumes resources), Cloudflare firewall rules (comes with 5 free rules which means you can block 5 bots), or the Blackhole For Bad Bots. I have a tutorial for blocking bad bots using all 3 methods. It depends on how many you want to block; if it’s only a few, I’d use Firewall Rules.

Login to your Cloudflare Dashboard and go to Firewall → Firewall Rules → Create A Firewall Rule. Copy the bad bot’s hostnames (from Wordfence) and add it here in the “Value” field. Since you can create 5 rules, you would repeat this step for your 5 worst bad bots from Wordfence.

  • Field = Hostname
  • Operator = Contains
  • Value = hostname of the bad bot you found in Wordfence

Cloudflare Firewall Rule To Block Bad Bots

Step 4: Go to your Blocking log in Cloudflare and watch your spam bots get blocked.



28. Identify Bottlenecks In Speed Testing Tools

GTmetrix – my tool of choice since you can find exactly which images, plugins, fonts, and external scripts take longest to load (plus it shows your time to first byte and redirect errors).


Pingdom – the most accurate tool for measuring your load times according to WP Rocket which is the primary metric you should be measuring (not grades), but there is a correlation.

Google PageSpeed Insights – good for measuring server response times but also has other recommendations like using next-gen format for images (eg. WebP), lazy loading, avoid third party scripts, preconnect, minification, caching recommendations, and serving scaled images.

Query Monitor – great for finding slow plugins, scripts, styles, and other elements slowing down your site. Make sure to delete it when you’re done since the plugin itself can be slow.

Get Help Fixing Your GTmetrix Report


Frequently Asked Questions

🚀 What are the most important speed factors?

Your infrastructure (hosting, theme, plugins, page builder, CDNs) have the biggest impact on load times.

🚀 Which cache plugin should you use?

WP Rocket is usually rated the top cache plugin in Facebook polls since it has built-in features most cache plugins don’t. These extra optimizations should yield better scores and load times in GTmetrix. The top free cache plugins are usually WP Fastest Cache, W3 Total Cache, and Swift Performance.

🚀 Which WordPress hosting should you use?

The best hosting is highly debatable, but Cloudways, SiteGround, and Kinsta generally the top 3 hosts based on 30+ Facebook polls.

🚀 Which speed testing tool should you use?

GTmetrix has the most robust recommendations especially for finding slow plugins, images, external scripts, and measuring TFFB. Pingdom doesn’t have as many recommendations, and Google PageSpeed Insights doesn’t measure load times.

🚀 How do you optimize images?

You can optimize images using a plugin like ShortPixel or Smush to compress images and strip EXIF data. Make sure you’re resizing images to the correct dimensions, and ideally serve them from a CDN. Lazy loading images and videos will also make the page faster.

🚀 Should you use AMP?

Generally, you should avoid AMP (accelerated mobile pages) since the design changes can lower conversions. Kinsta’s conversions dropped 59% after adding AMP and they decided to remove them.

🚀 How do you optimize plugins?

Find high CPU plugins using Query Monitor which usually include portfolios, statistics, sliders, and plugins that run ongoing processes. Next, replace them with lightweight plugins that consume minimal resources. Delete all plugins you’re not using, and disable unnecessary plugin settings that consume resources. Finally, selectively disable plugins from loading on certain content using a plugin like Asset Manager or Perfmatters.

🚀 How do you optimize external scripts?

It’s best to avoid external scripts all together, such as Google AdSense, Facebook widgets, and plugins that create external requests. Some plugins such as Disques let you load it conditionally. If the page contains JavaScript, try the Async JavaScript plugin. Finally, prefetch all external URLs that are loading on the page.

Really hope this helped! Drop your new GTmetrix scores + load times in the comments 🙂

Similar Posts

Leave a Reply

Your email address will not be published. Required fields are marked *