How do you figure out which bot traffic to block?

November 26, 2026 5 answers
Asked by Tivdaro.8q

My site is getting a lot of traffic that looks automated, and high bounce rates are making the analytics hard to interpret. Country challenges, bot user agent blocks, and rate limits have helped less than I expected. How do you tell what's worth blocking and keep the rest from using too many resources?

Answers

q.293~fendrixa

Start by checking where the suspected bot percentage comes from. Raw server logs count crawlers, link previews, uptime checks and other requests that aren't human visits. JavaScript analytics may filter or miss some of those, but it can still include automated traffic.

Compare the two for the same period and look at request paths, timing, user agents and network sources. A high bounce rate or a particular country isn't enough on its own to identify a bot. Keep a raw traffic view for investigating abuse and a separate filtered view for understanding visitor behavior.

Reply to this answer
p.684!quendrix

Protect the expensive stuff first. Search, login and database-heavy pages are better candidates for targeted rate limits or challenges than a cached homepage. Cache popular public pages where you can, and return obvious scanner requests at the edge instead of sending them through the app.

Check the effect on real visitors as you tune the rules. Some automated requests will get through, but they don't all need to be blocked if they're cheap to serve.

Reply to this answer
Mivquelo-2h

Country blocks are pretty blunt. Look for patterns in hosting and cloud provider networks instead, then consider challenges or rate limits for those networks where the behavior is suspicious. Legitimate users and services can use them too, so test before denying an entire network.

Ruvdelo+7k:

Request frequency and the paths being hit can help distinguish a noisy network from one that just happens to host useful services.

Reply to this answer
p.493~mavquelo

Be careful with broad user agent blocks. A crawler used for link previews may be useful even if you don't want a separate AI training crawler visiting. Blocking the preview fetcher can leave shared links without preview cards.

Robots.txt can express which crawlers you don't want, but it relies on them respecting the rules. It won't stop an uncooperative scraper, and a user agent string alone isn't proof of who's making a request.

Reply to this answer
Nexquaro+8f

An edge proxy or web application firewall can apply bot rules and rate limits before requests reach your app. If you already use one, check whether the origin is reachable directly. Traffic sent around the proxy won't encounter its rules, so that can explain why the changes seem to have little effect.

Reply to this answer

Add your answer

Answers are reviewed before publication.

Related Discussions