Every site has a finite number of pages worth crawling. A spider trap is a part of the site that pretends otherwise: a calendar with a "next month" link that never runs out, a filter system that can stack options in any order, a relative link that adds another folder to the URL every time it is followed. To a crawler each of these looks like a fresh page, so it keeps going.
The cost is rarely dramatic on day one. It shows up as new pages taking weeks to be crawled, Search Console filling with "Crawled – currently not indexed" and duplicate URLs, server load from bots, and site audits that never finish. On large or frequently updated sites, it can mean Google spends most of its visits on URLs that should never have existed.
This guide explains the main causes of infinite URL spaces, how to find them in crawl data, log files and Search Console, which fix fits which cause, how to stop developers creating new ones, and how to measure whether your changes worked.
What makes a URL space infinite
A spider trap does not need to be literally infinite. It only needs to generate URLs faster than they add value. Google's own explanation of the problem dates back to 2008, when it described calendars and product filters as the classic examples:
“The number of possible combinations of filters can grow exponentially.”
— Google Webmaster Central Blog, To infinity and beyond? No! (August 2008)
Google's current faceted navigation documentation says the same thing in modern terms: filter systems "can generate infinite URL spaces", which leads to overcrawling and slower discovery of new content. The underlying reason is that a crawler cannot know whether a URL is useful until it fetches it.
A quick way to see the scale: a category with five filter groups of eight options each, where any number of options can be combined and the order is not normalised, produces far more URLs than there are products. Add sort order (four options) and pagination, and a 300-product category can expose tens of thousands of crawlable addresses. All of them show some subset of the same 300 products.
Calendars, session IDs, relative links and filters: the usual culprits
Google's URL structure documentation lists four common causes of excessive URLs: additive filtering of a set of items, irrelevant parameters, calendar issues and broken relative links. In practice we see a few more. This table covers the patterns and what they look like in a crawl.
| Trap | Typical URL pattern | How it multiplies | Where it hides |
|---|---|---|---|
| Endless calendar | /events/?month=2031-07 | "Next" link always exists, even for empty months | Event plugins, booking widgets, archive sidebars |
| Session IDs in URLs | ?sid=a8f3..., ;jsessionid= | New ID per visit, so every crawl sees new URLs | Older ecommerce and Java platforms |
| Broken relative links | /blog/blog/blog/post/ | Each follow adds a path segment | Templates using href="blog/post" instead of /blog/post |
| Additive filters | ?color=red&size=m&color=blue | Every combination and order is a URL | Faceted navigation, recipe and job indexes |
| Sort and view parameters | ?sort=price&view=grid | Multiplies every listing page | Category templates |
| Internal search results | /search?q= | Any linked query becomes a page | "Popular searches" widgets, spam links |
| Endless pagination | ?page=9999 | Out-of-range pages return 200 with empty lists | Paginated archives |
| Tracking or cache-busting parameters | ?ref=footer, ?v=1712345 | Internal links carry unique values | Navigation built by marketing tools |
| Redirect loops between variants | A to B to A | Crawler cycles without reaching content | Conflicting trailing slash, locale or HTTPS rules |
Internal search deserves special mention because it is easy to overlook; see our guide to internal site search pages. Faceted navigation has its own detailed treatment in our faceted navigation guide, and parameter handling generally in URL parameters and SEO.
Spotting traps in crawler data
A desktop crawler is the quickest way to reproduce a trap, because it behaves like a naive bot. Signs to watch for:
- The crawl never finishes, or the URL count keeps climbing long after it should have plateaued.
- Crawl depth keeps increasing. A healthy site has most pages within a few clicks. A trap shows URLs at depth 20, 50 or 200.
- Many URLs share one title or one canonical. Hundreds of URLs titled "Events – July" is a calendar trap.
- URL length keeps growing. Repeated path segments point to relative link problems.
- A small set of parameters accounts for most URLs.
Practical settings: set a maximum crawl depth and a maximum number of query parameters, then run a second crawl without those limits on a sample section to see where it explodes. Export all URLs and group them by path pattern and parameter name. Our Screaming Frog guide covers the relevant settings, and Python for SEO shows how to group large URL exports by pattern. If templates hide the cause, custom extraction can pull out the link element responsible.
Remember that a crawler shows what is possible. It does not tell you what Googlebot actually does. For that you need logs.
Reading the trap in log files and Search Console
Server logs
Log files show every request Googlebot makes. Filter to verified Googlebot traffic (Google documents verification by reverse DNS, with hostnames ending in googlebot.com, google.com or googleusercontent.com, or by matching its published IP range files), then group requests by URL pattern. The question is simple: what share of Googlebot requests go to URLs you want indexed?
| Log metric | What it tells you | Warning sign |
|---|---|---|
| Googlebot hits by URL pattern | Where crawl activity is going | A parameter or folder takes a large share but has little indexed content |
| Unique URLs crawled per pattern | How many variants Google is discovering | Thousands of unique URLs under a pattern that should have dozens |
| Status codes by pattern | Whether traps return 200, 404 or 30x | Empty filters and out-of-range pages returning 200 |
| Time from publish to first Googlebot hit | Discovery speed for new content | New pages waiting days or weeks |
| Recrawl frequency of key pages | Whether important pages are refreshed | Money pages crawled less often than calendar URLs |
Our log file analysis guide covers how to collect and process logs.
Search Console
Without log access, Search Console gives useful proxies:
- Crawl Stats report: total requests, response breakdown, file types, and the split between discovery (first-time fetches) and refresh. A spike in discovery requests without a matching publishing spike suggests a new URL space. Examples of crawled URLs in each category often reveal the pattern directly. See our Crawl Stats guide.
- Page indexing report: large counts under "Crawled – currently not indexed", "Duplicate without user-selected canonical" or "Alternate page with proper canonical tag" with parameterised examples.
- URL Inspection: for an example trap URL, check the referring page to find the link that created it.
Matching the fix to the trap
There is no single fix. Google's documentation offers several tools, each with different strength and side effects. The most reliable approach is to stop generating the links in the first place, then use crawl controls for anything left.
| Fix | Best for | Strength | Side effects |
|---|---|---|---|
| Remove or change the link at source | Relative links, tracking parameters, "next" links on empty months | Strongest: no link, no URL | Needs developer time |
| Root-relative or absolute URLs | Broken relative links | Strong | None |
| Cookies instead of session IDs | Session parameters | Strong | Platform change may be needed |
| robots.txt disallow | Filters, sorts, internal search, calendar parameters | Strong for crawling | Blocked URLs can still be indexed without content if linked; canonical signals on them are not seen |
| Return 404 for empty or invalid combinations | Out-of-range pagination, empty filters, duplicate filters | Strong over time | Requires app logic |
rel="nofollow" on links | Future calendar pages | Moderate; every link to the URL needs it | Easy to miss a link |
rel="canonical" | Variants you want consolidated but crawlable | Weaker for crawl reduction | Google still has to crawl to see it |
noindex | Pages you want crawled but not indexed | Not a crawl fix | Google must crawl to see it |
Google's specific advice for some of these is worth quoting directly. On sessions: "Wherever possible, avoid the use of session IDs in URLs and consider using cookies instead." On calendars:
“If your site has an infinite calendar, add a nofollow attribute to links to dynamically created future calendar pages.”
— Google Search Central, URL structure best practices
On faceted navigation, Google says canonical and nofollow are less effective in the long run than robots.txt for reducing crawling, and recommends returning a 404 for filter combinations with no results, for duplicate or nonsensical filters and for nonexistent pagination.
A robots.txt example for common traps
User-agent: *
# Sort and view parameters
Disallow: /*?*sort=
Disallow: /*?*view=
# Session IDs
Disallow: /*?*sid=
Disallow: /*;jsessionid=
# Internal search
Disallow: /search
# Calendar beyond the event listing itself
Disallow: /events/*?month=
Test any pattern against real URLs before deploying, because a broad wildcard can block pages you want crawled. Our guide to robots.txt versus meta robots explains when each applies. And as Google's 2008 post put it: "don't forget to verify that Googlebot can find all your content some other way."
A step-by-step clean-up for an existing trap
- Quantify it. From logs or Crawl Stats examples, estimate how many Googlebot requests per day go to the trap pattern.
- Find the link source. Use a crawler's inlinks report or URL Inspection to find the template that generates the links.
- Decide what should be indexable. Some filter pages (for example, "red dresses") may deserve to rank. List those explicitly.
- Fix links at source for anything that is simply a bug: relative links, session IDs, tracking parameters, empty "next" links.
- Return correct status codes for empty, invalid and out-of-range URLs.
- Block the remaining pattern in robots.txt, leaving the indexable subset crawlable through clean URLs.
- Keep sitemaps clean so they list only canonical, indexable URLs.
- Monitor for four to eight weeks before judging the result.
Worked example (hypothetical): an events venue site has 900 real pages. Logs show Googlebot making about 6,000 requests a day, 4,700 of them to /whats-on/?date= URLs stretching years into the future, most returning an empty "No events" page with a 200 status. The fix: stop rendering the "next month" link beyond the last month with events, return 404 for empty future months, and disallow /whats-on/?date= in robots.txt while keeping the main listing and individual event pages crawlable. Eight weeks later, the team measures what share of Googlebot requests now go to event pages and how quickly newly announced events are first crawled. Those two numbers, not total crawl volume, show whether the trap is closed.
Stopping new traps before they ship
Most traps are created by ordinary development work: a new filter, a plugin, a redesigned pager. A short checklist in the release process prevents most of them.
- Any new link-generating component (filters, calendars, pagers, "related" widgets) gets an SEO review before launch.
- Internal links always use root-relative or absolute URLs.
- Filter parameters are applied in a fixed order and duplicates are rejected.
- Empty and invalid states return 404, not a 200 page saying "nothing found".
- Tracking parameters are never added to internal links; use event tracking instead.
- Staging environments are crawled with the same depth and parameter limits before release; see our guide to staging site SEO.
- A weekly automated crawl of a sample section alerts if URL counts jump.
Locale and geo logic can also create loops; if your site redirects visitors by country, read our guide to IP-based redirects as well.
Measuring crawl improvement after the fix
Do not judge success by total crawl requests. A drop in requests might mean the trap is closed, or it might mean Google is crawling less of everything. Track these instead:
- Share of Googlebot requests to indexable URLs (from logs). This should rise.
- Requests to the trap pattern. These should fall, though not to zero immediately; Google may still revisit known URLs for a while.
- Time to first crawl for new pages. This should shorten.
- Page indexing report counts for duplicate and "crawled – not indexed" URLs. These should decline over weeks.
- Server load from bots, which matters for hosting costs and site speed.
Keep the scale in proportion. Google's own crawl budget guide is aimed mainly at large sites (it gives rough figures of 1 million+ unique pages changing weekly, or 10,000+ pages changing daily). A 200-page brochure site with a calendar trap has a waste problem and an index quality problem more than a budget problem. Our guides to crawl budget, index bloat and large-site SEO explain where the line sits.
Google also notes that soft 404s "will continue to be crawled, and waste your budget", which is why returning proper error codes for empty pages matters as much as blocking.
Questions SEOs ask about spider traps
Is a spider trap a penalty risk?
No. It is a crawl efficiency and index quality problem, not a policy violation. The cost is slower discovery of real pages, duplicate URLs in the index and extra server load.
Should I use robots.txt or canonical tags for filter URLs?
Google's faceted navigation guidance says robots.txt is more effective in the long run for reducing crawling, while canonical and nofollow are weaker. Use canonical where you want variants crawled but consolidated.
Will blocking a trap in robots.txt remove the URLs from Google's index?
Not necessarily. Blocked URLs can remain indexed without content if they are linked. Fixing links at source and returning 404 for invalid URLs helps them drop out.
How do I find what is creating trap URLs?
Use a crawler's inlinks report or the referring page shown in URL Inspection to find the template or component generating the links, then fix it there.
Do small sites need to worry about spider traps?
Less about crawl budget, which Google frames as a large-site concern, but traps still create duplicate URLs and wasted crawling, so it is worth closing obvious ones like endless calendars.
Closing your site's crawl traps this quarter
Run a capped crawl and a log sample this week, group URLs by pattern, and list every pattern where crawl volume far outstrips indexable pages. Fix link bugs at source first, then return correct status codes, then block what remains. Measure the share of Googlebot hits going to real pages before and after.
If you want a crawl and log audit, our technical SEO team can find and close traps, and our ecommerce SEO service handles faceted navigation on large catalogues. Get a quote for a crawl efficiency audit.
Further reading on spider traps
- How to Remove Pages and Outdated Content From Google Search
- Meta Refresh and JavaScript Redirects: Do Search Engines Follow Them?
- SEO for Developers: What Engineers Need to Know Before Shipping
- Moving Your Business Location: Protect Local Rankings During a Move
Sources for this spider traps guide
- URL structure best practices for Google Search – Google Search Central
- Managing crawling of faceted navigation URLs – Google Search Central
- Crawl budget management for large sites – Google Search Central
- To infinity and beyond? No! – Google Webmaster Central Blog (August 2008)
- Crawl Stats report – Search Console Help
- Verifying Googlebot and other Google crawlers – Google Search Central




