> ## Documentation Index
> Fetch the complete documentation index at: https://docs.crispstats.com/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> CrispStats is a hosted, privacy-first web analytics product. It has no self-hosted edition, no session replay, no heatmaps, no A/B testing, no mobile SDKs and no data import except a site's history from a Plausible export (Settings, Import and export).
> The script global is crispstats(...), site keys start with cs_pk_ and secret API keys start with cs_sk_. The script is served from https://in.crispstats.com/d.js and the REST API lives at https://crispstats.com/api/v1.
> There is no npm package to install. Integrations copy the script tag, the queue stub, crispstats.d.ts and proxy code from these docs or from Settings, Tracking code in the dashboard. A first-party proxy forwards one path of the site to https://in.crispstats.com/p/ and forwards only content-type, user-agent, accept-language, referer, origin, if-none-match and x-forwarded-for, never cookies.

# How bots and automated traffic are filtered

> What the CrispStats script skips, what the collector drops silently, how to choose the off, standard or strict bot filter, and how AI crawlers are counted apart.

CrispStats keeps automated traffic out of your numbers in two places. The script does not run in automated or prerendered browsers, and the collector drops requests from software that identifies itself as a bot, from HTTP clients and from prefetches, before anything is stored. You choose how strict the collector is in **Settings**, **General**, **Bot filtering**: **Standard** (the default), **Strict** or **Off**. AI crawlers are never counted as visits; you report them separately and see them on the **AI traffic** page (see [AI crawlers](https://docs.crispstats.com/ai/ai-crawlers.md)).

The rules target software that announces itself. A bot that runs a real browser and hides it can still be counted.

## Choose a bot filtering level

**1. Open the setting**

In the dashboard, open **Settings**, **General**, **Bot filtering**. Changing site settings needs the owner or admin role on the site.

**2. Pick a level and save**

Select **Standard**, **Strict** or **Off**, then **Save changes**.

The level applies to new events within about a minute of saving, once the collector refreshes its cached copy of your site settings. Events already stored are not recounted.

| Level | What the collector drops |
| - | - |
| **Standard** (default) | AI crawlers, plus everything in [standard rules](#standard-rules): self-identified bots, headless browsers and automation tools, link previewers, HTTP clients, requests without a browser User-Agent, prefetch and prerender requests, and verified bots. Right for most sites. |
| **Strict** | Everything Standard drops, plus requests that Cloudflare's bot score rates as likely automated (a score from 1 to 29). A few real visitors on unusual setups may go uncounted. |
| **Off** | Only AI crawlers. Everything else that runs the script is counted. |

## What the script skips

The script sends nothing when the browser reports that it is automated: when `navigator.webdriver` is true, which covers Selenium, Puppeteer and Playwright in their default modes, or when the page runs inside Cypress.

For a page that is being prerendered by the browser, tracking waits until the page is actually shown. A prerendered page the visitor never opens is not counted.

The script also stays silent on local pages without `data-allow-localhost`, on hostnames outside `data-domains`, with `data-dnt` in browsers that send Do Not Track, and when `localStorage.crispstats_ignore` is `"1"`. Those are your own [exclusions](https://docs.crispstats.com/tracking/exclude-traffic.md), not bot rules. In every case `window.crispstats` still exists, so calls to it are harmless.

## What the collector drops

Bots that do not run the script cannot send events. Bots that run it but hide `navigator.webdriver` reach the collector, which checks the User-Agent and request headers and drops them when those give the bot away.

### Standard rules

With **Standard** or **Strict**, an event is dropped when any of these is true:

* **No User-Agent**, or one that does not look like a browser: real browsers, including in-app webviews, start with `Mozilla/` (or `Opera/` for old Opera) followed by a version number. Anything else, or anything shorter than 30 characters, is dropped.
* **Self-identified bots**: the User-Agent contains `bot` at the start or end of a word, or `crawl`, `spider`, `slurp` or `scrape`.
* **Automation and monitoring tools**: headless browsers, PhantomJS, Puppeteer, Playwright, Selenium, Cypress, Lighthouse, PageSpeed, GTmetrix, WebPageTest, uptime and monitoring services such as Pingdom, StatusCake, Checkly, Datadog and New Relic, and prerender services.
* **Link previewers and fetchers**: Facebook, WhatsApp, Skype and other link previews, feed readers, archive crawlers and validators.
* **HTTP clients and scanners**: curl, wget, Python, Java, Go, Node.js fetch libraries, Postman, Ruby, PHP, Scrapy and similar clients, and network scanners.
* **Prefetch and prerender requests**: the request carries a `Sec-Purpose`, `Purpose`, `X-Purpose` or `X-Moz` header that mentions `prefetch`, `prerender` or `preview`.
* **Verified bots**: Cloudflare identifies the request as coming from a verified bot.
* **Certain automation**: Cloudflare's bot score for the request is 1.

**Strict** adds one rule: a Cloudflare bot score from 1 to 29, which Cloudflare treats as likely automated. When no score is available for a request, this rule does not apply.

### Other silent drops

The collector answers every browser event with an empty `202` at once and filters afterwards (only a body that is not a JSON object gets a `400`, and one over 16 KB a `413`), so a dropped event looks the same as an accepted one from the browser. Besides bots, it silently drops events:

* with a site key that does not exist,
* that fail validation, such as an event name over 120 characters or a property name over 60,
* from hostnames the site does not allow,
* from excluded paths and excluded IP addresses,
* for paused sites and sites of suspended workspaces,
* for a workspace in its trial that has reached its 25,000 events this month,
* for a workspace that is locked because it has no plan after its trial or plan ended,
* over the rate limit of 1,200 requests per minute from one address at one Cloudflare location.

On a paid plan, going over the monthly allowance never drops events. In the trial, events over 25,000 in a month are not recorded: see [when the trial reaches its event limit](https://docs.crispstats.com/account/plans-and-limits.md#when-the-trial-reaches-its-event-limit).

## How AI crawlers are counted

AI crawlers such as GPTBot, ClaudeBot, PerplexityBot, Google-Extended and CCBot fetch your pages without running JavaScript, so they never reach the script. If one does send an event to the collector, it is dropped at every level, including **Off**, so it never inflates your visitors.

To count them, report crawler hits from your server or edge with `POST https://in.crispstats.com/bot`. [Next.js](https://docs.crispstats.com/install/nextjs.md#report-ai-crawlers-from-proxy-ts) has a ready `proxy.ts`, and the [collector reference](https://docs.crispstats.com/api-reference/collector.md#post-/bot) has the payload. The collector matches the User-Agent against its list of AI crawlers, stores each hit with the crawler's name, operator and purpose (training, search or user), the path and the status, and ignores anything else. These hits appear on the **AI traffic** page in the dashboard and never in your visitor numbers. See [AI crawlers](https://docs.crispstats.com/ai/ai-crawlers.md) for the setup.

## Learn more on crispstats.com

* Glossary: [bot traffic](https://crispstats.com/glossary/bot-traffic) and [AI crawler](https://crispstats.com/glossary/ai-crawler).

## Next steps

> [card] [AI crawlers](https://docs.crispstats.com/ai/ai-crawlers.md)
>
> Report crawler hits from your server and see which AI companies read your site.

> [card] [Exclude traffic](https://docs.crispstats.com/tracking/exclude-traffic.md)
>
> Keep your own visits, staging hosts and admin pages out of your data.

> [card] [Troubleshooting](https://docs.crispstats.com/help/troubleshooting.md)
>
> Find out why visits are not showing up.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.