Who is really loading your server: bots, AI crawlers and what to do about them

The site has got slow and sometimes shows a 502. Analytics look normal, there are no more visitors than usual. You open the web server log and find thousands of requests, and almost none of them come from people.
We see this in support regularly. The server is fine, it's just being read by robots. And not only by search engines.
Who visits a site besides people
There are lots of bots, and they want different things.
- Search engine robots. Googlebot, Bingbot and others. Without them the site won't be in search results, so these are welcome guests.
- AI crawlers. They collect text to train language models or to answer questions in chatbots.
- SEO tools and scrapers. They map links, watch competitors' prices, copy catalogs.
- Vulnerability scanners. They try addresses like
wp-login.phpor/.env, looking for a way in or something to steal.
Bots introduce themselves in the User-Agent header. It's easy to fake, but the big companies label their robots honestly, so the log usually tells you right away who came.
Why now
Search robots have always been around, and sites got used to them long ago. AI crawlers are different: in a couple of years there have come to be many of them, almost every AI company has its own, and some have several.
A person opens five or ten pages. A robot goes through the whole site, page after page. It doesn't care whether a page is light or heavy, and that's the whole problem. A catalog with filters is thousands of addresses: every combination of color, size and price counts as a separate page. The same goes for site search, calendars and pages with parameters in the URL. Such pages hardly ever end up in the cache, so every request goes through PHP and the database.
While there are a dozen requests a minute, the server doesn't notice. When there are hundreds, the PHP processes are busy with bots, real visitors wait in line, and in the end nginx answers 502 or 504. What each of these errors means is covered in The site shows error 500, 502, 503 or 504.
One company, different robots
The big AI companies have split their robots by task. It's worth knowing before you block anyone.
- Model training. GPTBot from OpenAI, ClaudeBot from Anthropic. CCBot belongs here too: it's the robot of Common Crawl, an open archive of the web that many models are trained on. Block them, and the companies promise not to take the site's new texts for training. That's no guarantee your text won't reach a model some other way, say through a copy on someone else's site.
- Search in AI services. OAI-SearchBot, Claude-SearchBot, PerplexityBot. They are why a site shows up with a link in answers from ChatGPT, Claude and Perplexity. Block them, and there will be fewer such links.
- Requests on a person's behalf. ChatGPT-User, Claude-User, Perplexity-User. They come when a user has asked the assistant to open a page. OpenAI and Perplexity say plainly that
robots.txtmay not apply to these requests: they count them as a person's action, not as crawling.
Google-Extended is a separate case. It isn't a robot, just a token in robots.txt. Google crawls the site with the same Googlebot, and the token says whether the texts may be used to train and ground Google's AI products. Google itself says it doesn't affect the site's place in search. The AI answers in Google Search itself (AI Overviews) aren't turned off by this token; there's a separate setting in Search Console for them.
Block or not
There's no universal answer, but you can reason like this.
If you don't want models trained on your texts, block the training robots. Search won't be affected, and the load will go down.
AI search is already traffic. A shop or a service most likely benefits when ChatGPT or Perplexity recommends it with a link. Then it's better to keep the AI search robots. An internal portal or a closed project has no use for them.
And one rule with no exceptions: don't block Googlebot, Bingbot or other search engine robots, or the site will drop out of search. If it looks like Googlebot is the one overloading the server, first check that it's real. Other bots often pretend to be Googlebot. Google recommends checking it this way: do a reverse DNS lookup of the IP address, make sure the name ends in googlebot.com or google.com, then do a forward lookup to check that this name points to the same address. If the check fails, it isn't Google, and you can block that bot without a second thought.
What to do in practice
First make sure it really is bots. To find out, look in the web server log for the addresses and User-Agents that send the most requests. The commands for that are in The server is slow or the CPU is at 100%, along with sample settings. Then step it up:
robots.txt. The big companies follow it, it's written in their documentation. Two lines are enough to shut out one robot. But remember thatrobots.txtis a request, not a lock: a robot doesn't have to obey it.- Blocking on the web server. For those who ignore
robots.txt, nginx or Apache can simply refuse by User-Agent. The robot gets an error, and PHP and the database don't even wake up. - Cache. If a page is served from the cache, a bot costs almost nothing. WordPress and other CMSs have caching plugins, and nginx can cache on its own. That saves ordinary pages. Catalog filters and search hardly ever get cached, so it is better to close them to robots in
robots.txt. - Cloudflare. It cuts bots off before their requests reach your server. Blocking AI bots there is a setting, available on the free plan too. How Cloudflare works and how to connect it, we explained in What is CloudFlare and how does it work?.
The first two steps are usually enough. The rest come in handy if the site is large or there are a great many bots.
If bots aren't to blame
Sometimes there are no extra requests, and the site is still slow. Then the cause is something else: not enough memory, a full disk or heavy database queries. How to check that is also in The server is slow or the CPU is at 100%. And if the site has simply grown, you can add CPU, memory and disk in the control panel without reinstalling: Reconfiguring a virtual server.
Can't work out what's loading the server? Contact support, and we'll look into it together.
