How to stop web scraping
Learn how modern scrapers collect your prices, content and data - and what actually works to stop them
How to stop web scraping bots
Web scraping becomes a business problem when automated visitors copy data at a scale, frequency or purpose you did not agree to: prices for repricing, inventory for competitive intelligence, product catalogues for replication, or original content for reuse elsewhere.
The hard part is not blocking “a scraper”. It is separating extraction you want – search engines, approved partners and selected AI crawlers – from automation that takes value without giving anything back.
TL;DR
Stopping web scraping takes five steps: confirm the pattern in server-side traffic, map the data worth protecting, separate verified crawlers from untrusted automation, close the cheap gaps, and enforce the policy at the perimeter. robots.txt is useful for compliant crawlers, but it is not access control. Rate limits and user-agent rules can reduce obvious scraping, but modern protection needs multiple signals and continuous enforcement.
By [Author] · Reviewed by [Security Lead], ADPAL · Updated 20 August 2026
OWASP classifies scraping as a distinct automated threat to web applications. Its automated-threat framework is useful because scraping often abuses normal, public functionality rather than exploiting a software vulnerability. Source: OWASP OAT-011 Scraping.
First: understand the scraping workflow
Most commercial scraping is a pipeline, not a person repeatedly refreshing your website. The exact tooling varies, but the business workflow is usually simple: choose a target, fetch pages or endpoints, extract structured fields, then reuse the data somewhere else.
For an eCommerce store, that may mean prices, availability, SKUs and promotions feeding a competitor-intelligence or repricing system. OWASP even uses continuous competitor-store scraping and dynamic pricing as an example of automated business activity.
01
Target. Valuable pages or endpoints are selected: product pages, category pages, search, availability or public APIs.
02
Fetch. Automation requests those resources repeatedly, sometimes in a predictable sequence and sometimes deliberately spread out.
03
Extract. Prices, stock, copy, metadata or structured fields are parsed into a machine-readable dataset.
04
Reuse. The data feeds a dashboard, model, catalogue, alerting system or another website.
Why this matters
You are not trying to discourage a human researcher. You are deciding whether an automated data pipeline should be allowed to keep reading your assets.
Step 1: confirm scraping with evidence, not one suspicious user-agent
Start with server or reverse-proxy logs. Analytics can show unusual traffic, but scraping detection is stronger when you can see the requests themselves: which URLs were fetched, how often, from where, and in what order.
Avoid the common shortcut of declaring every Python, cURL or datacentre request malicious. Those are useful clues, not proof. Legitimate tools use HTTP libraries and cloud infrastructure too. The strongest case comes from several signals lining up.
| Signal | What to look for | Do not overinterpret it |
|---|---|---|
| 01Systematic page enumeration | Product or category URLs are requested in a structured sequence. | Legitimate crawlers can also enumerate. Verify identity and policy before blocking. |
| 02High concentration on data-rich paths | A client repeatedly hits product, search, availability or API endpoints. | Monitoring tools and partners may do the same. Context matters. |
| 03Traffic without matching business activity | Requests rise while carts, leads or sales do not move with them. | Campaigns, SEO crawling or monitoring can create similar gaps. |
| 04Repeated extraction over time | The same dataset appears to be refreshed on a schedule. | One burst may be indexing. Repetition is stronger evidence than one spike. |
| 05Competitor behaviour mirrors your changes | Prices, availability or launches are reflected unusually quickly elsewhere. | Treat this as a business signal, then confirm with traffic evidence. |
30-minute audit
Take the 20 highest-volume clients hitting your product, catalogue or search paths. Compare their request sequence, request rate, referrer pattern and conversion or lead activity. Then separate known crawlers and partners from traffic you cannot explain.
No useful log access? Scan my site to establish which automated traffic is reaching the website before you start adding blocking rules.
Step 2: map what the scraper can take
Scraping protection becomes easier to prioritise when you stop thinking in pages and start thinking in business assets. The same scraper may touch several assets during one crawl.
- Prices and promotions. Useful for repricing, monitoring and competitive intelligence.
- Stock and availability. Useful for market timing, fulfilment comparisons and automated alerts.
- New launches. Valuable when first-mover advantage matters.
- Catalogue structure. Product names, categories, attributes and taxonomy reflect research and merchandising work.
- Original text and media. When the goal is republication rather than data analysis, the issue overlaps with content theft.
- Public or semi-public API responses. Headless storefronts and mobile applications may expose the same valuable data more efficiently than rendered HTML.
Prioritise by business value
Do not spend the same effort protecting an About page and a live price-and-stock endpoint. Start with the data that gives another business an advantage when copied frequently.
Step 3: separate the crawlers you want from the automation you do not
The objective is not to block crawling. Search engines crawl your site so it can appear in search. Approved comparison partners, monitoring services and other tools may also be commercially useful. Your policy should answer two questions: who is this crawler, and what access do you actually want to give it?
Do not trust a familiar user-agent string by itself. Google explicitly warns that Googlebot user-agents are spoofed and recommends reverse/forward DNS verification or comparison with published Google crawler IP ranges. Source: Google crawler verification.
- Verify important search crawlers. Allow the real crawler, not anyone wearing its name.
- Identify approved partners. Document which automated services are part of your business model.
- Decide AI crawler policy separately. Training, search/answer crawling and user-request fetching are different jobs. See How to block AI crawlers.
- Treat unknown automation as unverified. That does not automatically mean malicious; it means it should not inherit trusted-crawler privileges.
Step 4: close the cheap gaps – and know their ceiling
Several low-cost controls are worth using. The mistake is treating any one of them as complete anti-scraping protection.
| Control | Useful for | Limit |
|---|---|---|
| 01robots.txt | Declare crawl preferences to compliant crawlers. | RFC 9309 is explicit: robots.txt rules are not access authorisation. |
| 02Rate limiting | Reduce excessive request volumes on expensive or data-rich paths. | A distributed or deliberately slow scraper may stay below a simple threshold. |
| 03User-agent rules | Remove the most obvious tools or apply policy to verified named crawlers. | The sender controls the header. A serious scraper can change it. |
| 04CAPTCHA / challenges | Add friction to selected suspicious interactions. | Poor fit for every product-page request and creates customer friction when overused. |
| 05Authentication | Protect genuinely private data and customer-only workflows. | Do not hide public catalogue data behind login merely to fight scraping; the cure can damage UX and SEO. |
The robots.txt point is especially important. The Robots Exclusion Protocol lets a site publish rules that crawlers are requested to honour, but the standard explicitly says those rules are not a form of access authorisation. Source: RFC 9309.
Rate limiting remains useful. Use tighter budgets around data-rich and computationally expensive endpoints. Just design limits around normal customer and partner behaviour, and review what happens during promotions or traffic peaks before enforcing aggressively.
Good quick wins
Publish clear crawler policy, verify the major search crawlers, apply sensible rate limits to extraction-heavy endpoints, remove unnecessary public data exposure, and block only the obvious automation you can identify with confidence. Then measure what remains.
Step 5: enforce the policy at the perimeter
The difficult scrapers are the ones that do not present a useful name or obvious fixed source. They can use normal browser stacks, distributed networks and request pacing that avoids crude thresholds. At that point, detection has to move from one static identifier to the pattern of requests.
For ADPAL, the relevant signal set is behaviour, browser, network, request sequence and endpoint. Correlating those signals lets the protection layer distinguish automated extraction from the traffic that should remain available, without making a user-agent string the source of truth.
Perimeter placement matters because the decision is made before the request reaches the protected application. If a scraping request is blocked there, the origin does not need to render the page or return the protected response.
Policy before blocking
Keep verified search engines and approved automation available. Block or limit extraction that conflicts with your policy. The goal is not maximum blocking; it is minimum unwanted extraction with minimum customer and SEO impact.
How to tell whether anti-scraping protection is working
Do not judge success by a dashboard number called “bots blocked”. Measure whether the business problem changes.
- Origin request volume: did repeated catalogue or search requests reaching the application fall?
- Data-rich endpoint load: are the pages and APIs most attractive to scrapers quieter?
- False positives: do Google, Bing, approved partners and real customers continue to work normally?
- Scraping recurrence: does the same extraction pattern reappear from new sources after a block?
- Business signals: if you suspected price or launch monitoring, does the external behaviour that triggered the investigation change after enforcement?
Keep a baseline
Capture one week of request and business data before enforcement where practical. Without a baseline, you can prove that rules fired, but not that the scraping problem improved.
Five anti-scraping mistakes to avoid
01
Blocking all crawlers. You can damage search visibility and useful partnerships while the scraper simply changes identity.
02
Trusting the user-agent. A name is a claim. Verify the crawlers whose access matters.
03
Using robots.txt as a lock. Keep it for crawler policy; enforce unwanted access elsewhere.
04
Rate-limiting the whole site with one threshold. Different endpoints, customers and partners have different normal patterns.
05
Waiting for a legal dispute to solve a technical access problem. Scraping law varies by jurisdiction and facts. This guide is not legal advice; technical controls let you enforce your own access policy now.
How ADPAL handles scraper automation
ADPAL runs in front of the protected website. Advanced detection evaluates behaviour, browser, network, request sequence and endpoint so unwanted automation can be stopped before it reaches data-rich application flows.
Verified search crawlers and automation you choose to permit can remain accessible. Unknown or deceptive automation does not gain trusted access simply because it claims a familiar identity.
Cookieless, no cross-site tracking profiles, EU (Frankfurt) data residency.
Deployment
Point your DNS at the managed reverse proxy – live in hours, then a short monitoring period before enforcing. CMS-integrated deployment is available through hosting partners.
Frequently asked questions
How do I detect web scraping on my website?
Start with server or reverse-proxy logs. Look for repeated requests to data-rich pages or APIs, systematic URL enumeration, unusual request concentration and traffic that has no matching business activity. No single signal proves scraping; combine request evidence with crawler verification and business signals.
Can robots.txt stop web scraping?
Not by itself. robots.txt communicates crawl rules to compliant crawlers, but RFC 9309 explicitly says those rules are not access authorisation. Keep robots.txt for crawler policy and SEO hygiene; enforce unwanted scraping with traffic controls.
Can rate limiting stop scraper bots?
It can reduce obvious or high-volume scraping and is worth using around expensive or data-rich endpoints. It is not complete protection because automation can distribute requests or operate below one simple threshold. Rate limiting works best as one layer in a broader policy.
Will blocking web scrapers hurt Google rankings?
It should not if you verify and allow the real search crawlers instead of blocking by name or with an over-broad rule. Google publishes verification methods and crawler IP information specifically so site owners can distinguish genuine Google traffic from impostors.
Should I block every scraper?
No. Search crawlers, approved comparison partners, monitoring tools and selected AI crawlers may be useful. Decide access by business value and verified identity. The problem is unwanted extraction, not automation as a category.
How do I stop AI bots from scraping my site?
Set a separate policy for AI crawlers because training, AI search and user-request fetching are different jobs. robots.txt can express policy for compliant crawlers, while undeclared or non-compliant automation needs traffic-level enforcement. See How to block AI crawlers.
Is web scraping illegal?
There is no universal yes-or-no answer. Lawfulness depends on jurisdiction, the data, how it is accessed, contractual terms and what is done with it. This article is technical guidance, not legal advice. If the legal status matters to a dispute, use qualified counsel in the relevant jurisdiction.
Stop feeding an extraction pipeline you never approved
Web scraping is easiest to manage when the policy is explicit: know what data matters, verify the automation you want, reduce obvious exposure, then enforce unwanted extraction before it reaches the application.
If you suspect competitors, aggregators or unknown bots are repeatedly reading your catalogue, prices or content, measure the traffic first. A clean baseline makes every later decision safer.
Next step
See which automated visitors are reaching your site, which endpoints they target and which traffic deserves a closer look.