A store owner gets a warning from their host about CPU usage. Traffic in analytics looks normal. Sales look normal. The server is at its limit every afternoon and nobody can say why.
When the load is coming from bots crawling your product filters, analytics will never show it, because the requests are not people and most of them never run your tracking script. This guide covers how filter URLs turn a modest catalogue into millions of expensive page requests, how to identify what is hitting you, and how to stop it at the cheapest possible layer.
Why product filters are so expensive
Every filtered URL on your store is a unique address. A page with six attribute filters, a price slider and three sort orders does not produce nine URLs. It produces every combination of them, which runs into the thousands or millions depending on your catalogue.
Three things make each of those requests costly:
- They miss the page cache. A cache serves saved HTML for addresses it has seen. A crawler walking combinations generates addresses nobody has ever requested, so almost every hit is a cache miss that runs the full product query.
- Add to cart requests create a session. Every hit on an add-to-cart URL from a new client creates a row in the WooCommerce sessions table, whether or not anything was bought.
- They run PHP and MySQL. A product query with attribute and price filtering is one of the heaviest things WooCommerce does.
So the bot is not hammering you with volume in the way a denial of service would. It is picking the single most expensive request your store can serve and repeating it.
Why the defences you already have are not working
Most stores in this situation already tried three things, and there is a reason each one underperforms.
robots.txt only guides crawlers that choose to obey
It is still worth writing, because it stops well behaved crawlers from wasting your budget. It has no effect at all on anything that ignores it, and the traffic causing your CPU problem is usually in that group.
A security plugin blocks inside PHP
Wordfence and similar plugins are excellent at what they do, but they run as WordPress plugins. By the time they decide to block a request, WordPress and the plugin stack have already loaded. The request is refused, but you still paid most of the CPU cost of serving it. Under sustained crawling this is the difference between a plugin that protects you and a plugin that becomes part of the load.
Rate limiting assumes one source
A rate limit counts requests per IP. When traffic arrives from hundreds of addresses, each one stays comfortably under the threshold while the aggregate flattens your server. This is the single most common reason owners conclude that their protection is broken when it is simply measuring the wrong thing.
Identify before you block
Do not add rules yet. Open the raw access log in your hosting panel, or Live Traffic in Wordfence, and read twenty or thirty requests that hit filter, cart and category URLs. You are looking for three things.
- The user agent. Many scrapers and AI crawlers identify themselves honestly. Some send nothing at all, which is itself a signal, because real browsers always send one.
- The referer. A customer who clicks a filter on your site arrives with a referer from your own domain. A bot replaying URLs from a list usually sends none.
- The IP spread. A handful of networks, or addresses from everywhere?
Those three answers decide which of the fixes below will work. Skipping this step is how people end up blocking their own customers.
Fix it at the cheapest layer that works
The guiding principle is that a request you reject before PHP loads costs almost nothing, and a request you reject inside WordPress costs nearly as much as serving it. Work outwards from the server.
Reject empty and named bad user agents in htaccess
If your log shows a consistent user agent, or requests with no user agent at all, this stops them before WordPress starts. Place it above the WordPress block in your htaccess file.
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTP_USER_AGENT} ^$ [OR]
RewriteCond %{HTTP_USER_AGENT} (ExampleBot|OtherBot) [NC]
RewriteRule ^ - [F,L]
</IfModule>
Block filter and cart URLs that arrive with no referer
This is the most effective rule for this specific pattern, and the least known. A real customer clicking a filter sends a referer. A bot replaying a list usually does not.
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{QUERY_STRING} (^|&)(add-to-cart|orderby|min_price|max_price|filter_[a-z0-9_-]+)= [NC]
RewriteCond %{HTTP_REFERER} ^$
RewriteRule ^ - [F,L]
</IfModule>
Note the trade-off honestly: someone opening a bookmarked filter link, or arriving from a source that strips the referer, will get a 403 while this rule is active. That is usually acceptable during an attack and should not be left on forever. If you use a filter plugin, open a filtered page, read the parameter names in the address bar, and add them to the pattern.
Kill dead URL prefixes at the server, not in WordPress
If bots are hammering a language prefix or an old path you removed, every request still loads WordPress just to render a 404. Answer it before WordPress starts:
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteRule ^en(/.*)?$ - [G,L]
</IfModule>
Cache the archives so bot hits stop mattering
Shop, category and tag pages are ordinary archives and can be served as saved HTML. Once they are cached, a bot hitting them costs very little. Cart, checkout and my account must stay out of the cache. Most cache plugins exclude them automatically for WooCommerce, but check rather than assume.
When the traffic looks human, move to the edge
If the IPs are spread everywhere and the user agents look like ordinary browsers, your server cannot tell them from customers and no htaccess rule will separate them. The filtering has to happen before the traffic reaches your host. Cloudflare on the free plan can do this. Turn on Bot Fight Mode and add a WAF rule with the action Managed Challenge targeting filter and cart query strings. People pass the challenge in a second or two. Most bots do not, and the blocked requests never reach your server at all.

My take: filters are a liability the ecosystem sells as a feature
Faceted filtering gets added to stores because it looks like better navigation, and on a catalogue of two hundred products it is. Past a few thousand products, every filter you add multiplies the number of expensive, uncacheable addresses your store exposes to the internet, and nobody mentions that when selling you the plugin.
My position is that filter URLs should be treated as a surface to defend rather than a feature to expand. Before adding another facet to a large catalogue, it is worth asking whether customers actually use it, because each one has a permanent cost that shows up as a hosting bill rather than a slow page.
The other thing worth saying: your host telling you to upgrade your plan is not a diagnosis. More CPU makes the same wasted work cheaper to absorb. It does not stop the waste.
How to fix this on your store
- Ask your host for an access log sample covering one CPU spike, with timestamps, URLs and query strings, IP addresses, user agents and response codes.
- Read twenty or thirty of the filter and cart requests. Note the user agent, whether the referer is empty, and whether the IPs cluster.
- Check how large your sessions table has grown, since add-to-cart crawling inflates it.
- Add robots.txt rules for your filter and sort parameters. It costs nothing and helps with the polite crawlers.
- Apply the htaccess rules that match what your log actually showed, not all of them.
- Confirm your shop, category and tag pages are page cached, and that cart, checkout and my account are excluded.
- If the traffic is distributed and looks human, put Cloudflare in front and challenge filter and cart query strings.
- Place a test order after every htaccess change. Always.
That last point is not a formality. A referer rule with a typo in the parameter list can block add-to-cart for real customers, and you will not see it in your own browser because your requests carry a referer.
Find out what is actually hitting your store
If your server is under load and the cause is not obvious, a WooCommerce technical review works through the access logs, the cache configuration and the query cost together, which is usually faster than trying rules one at a time. For stores where the problem is genuinely page speed rather than traffic, page speed optimisation is the better starting point.
Related reading: which WooCommerce filter URLs deserve to be indexed, what to investigate before adding more cache, and why card testing bots bypass your checkout CAPTCHA.
Frequently asked questions
How do I tell bot traffic from real visitors in WooCommerce?
Compare your access log against your analytics. Bots rarely run JavaScript, so traffic that appears in the server log but not in analytics is usually automated. In the log itself, look for requests with no user agent, no referer on filter and cart URLs, and a pattern of walking query string combinations rather than browsing naturally.
Does robots.txt stop bots from crawling WooCommerce filter URLs?
Only for crawlers that choose to obey it, which includes search engines but excludes most scrapers. It is still worth adding rules for your filter, sort and add-to-cart parameters because it prevents well behaved crawlers wasting your crawl budget. It will not reduce CPU load caused by bots that ignore it.
Why is Wordfence not reducing my server load?
Wordfence blocks inside PHP, so WordPress has already loaded by the time a request is refused. The block works, but you still pay most of the cost of the request. To actually reduce load you need to reject the traffic earlier, in htaccess at the server level or at a CDN or firewall in front of the site.
Can product filters cause high CPU usage on WooCommerce?
Yes, and they are one of the most common causes. Filtered URLs bypass the page cache because each combination is a unique address, and each one runs a heavy product query against the database. A crawler walking those combinations generates sustained database and PHP load that never appears in your analytics.




