> ## 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.

# Privacy and compliance facts for CrispStats

> A factual sheet for a privacy or legal review of CrispStats: cookies, storage, IP and User-Agent handling, identifiers, processors, retention and contacts.

CrispStats sets no cookies, stores nothing on the visitor's device in its default setup, and never stores IP addresses or User-Agent strings. Visitors are counted with an anonymous id that rotates every day and cannot be linked across days or sites. Two options change this, and only when you turn them on: persistent visitors, which stores a random id in the browser, and `identify()`, which attaches your own user id to events.

This page collects the facts a privacy or legal reviewer usually asks for, with links to the detail. It describes how the product behaves. It is not legal advice: whether you need consent or a banner depends on your setup and the rules where you and your visitors are, and your own counsel should decide that.

## Fact sheet

These facts describe the default script tag with no options.

| Question | Answer |
| - | - |
| Does the script set cookies? | No. |
| Does it write to `localStorage`, `sessionStorage` or IndexedDB? | No. It reads one key, `localStorage.crispstats_ignore`, which only a site owner sets to exclude their own browser. |
| Is the IP address stored? | No. It is read in memory to compute the visitor id, estimate the location, match excluded addresses and apply rate limits, then discarded. It is not logged. |
| Is the User-Agent stored? | No. It is read in memory for the visitor id, bot filtering and the browser, operating system and device type, then discarded. Only those three families are stored. |
| How are visitors identified? | By the first 32 hex characters of `SHA-256(daily salt, site id, IP address, User-Agent)`. The salt is random, changes at the start of each day in the site's timezone and is deleted 35 minutes after its day ends. See [cookieless tracking](https://docs.crispstats.com/privacy/cookieless-tracking.md). |
| Can a visitor be followed across days? | Not with the default setup. A session in progress when the site's day changes keeps its id for up to 30 minutes. |
| Can a visitor be followed across sites? | No. The site id is part of every hash. |
| How precise is the location? | Country, region and city from Cloudflare's network estimate. Coordinates are rounded to 0.1 degree, about 11 km. No browser location API is used. |
| Is the full URL stored? | The hostname and path. The query string is removed, apart from UTM values in their own fields. The fragment is not sent unless you use `data-hash` for a hash router. |
| Is the referrer stored? | Only the referrer's hostname, and only when it is another site. |
| Is Do Not Track honoured? | Only if you add `data-dnt` to the script tag. It is off by default. |

The full list of fields is on [what data CrispStats collects](https://docs.crispstats.com/privacy/data-collected.md).

## Options that change the picture

### Persistent visitors

Off by default. It needs both a site setting and the `data-persist` attribute. When on, the script stores a random id in `localStorage.crispstats_vid` and sends it with every event. The collector stores a per-site hash of it, so the same browser is recognised across days.

This stores an identifier on the visitor's device. Under the ePrivacy Directive, UK PECR and similar rules that generally requires consent first, and under GDPR the id is personal data. See [persistent visitors](https://docs.crispstats.com/privacy/persistent-visitors.md) for how to load it only after consent and how to delete the id.

### identify()

When you call `crispstats.identify(userId, traits)`, the user id you pass is attached to that event and to later events on the same page, and the traits are stored in that visitor's profile. CrispStats then groups that person's visits under your user id across days and devices, and retention cohorts count their returns. The script keeps the id in memory only and stores nothing in the browser. What you pass is up to you: an internal id reveals less than an email address. See [identify users](https://docs.crispstats.com/track/identify-users.md).

### Revenue attribution

Payments read from your payment provider may contain the customer's email address. The collector stores a SHA-256 hash of the lowercased address and a masked form such as `j***@e***.com`, never the address. To attribute a payment to a visit, you pass the visitor id to your payment provider in the `crispstats_visitor_id` metadata key, or as `client_reference_id` with Stripe Checkout. See [revenue attribution](https://docs.crispstats.com/revenue/overview.md).

### Data you send yourself

Custom event names and properties, `identify()` traits, page paths and JavaScript error messages and stacks (with `data-errors`) are stored as you send them. Keep personal data out of them unless you intend to collect it.

## Where data is processed

CrispStats is a hosted service. The collector and tracking script run on Cloudflare's network, which handles requests in transit, IP addresses included, and the data is stored in a Postgres database run by Supabase. The full list of subprocessors, with what each handles and where, is at [crispstats.com/legal/subprocessors](https://crispstats.com/legal/subprocessors). Anthropic receives data only when someone in your workspace uses Ask AI: the question, any picture or file they attach to it, the report figures needed to answer it and, when Ask AI reads the site's setup, the names of its goals, funnels, alerts and monitors, its monitor URLs and its chart notes.

The data processing agreement is at [crispstats.com/legal/dpa](https://crispstats.com/legal/dpa). It applies when you accept the terms of service, and you can ask for a signed copy at `privacy@crispstats.com`. The privacy policy for CrispStats itself is at [crispstats.com/legal/privacy](https://crispstats.com/legal/privacy).

## Retention and deletion

Traffic data is kept for 6 months during the trial, 24 months on Starter, 60 months on Growth, and for as long as you are subscribed on Scale. Payment records are kept on every plan until you delete the site or your account. A daily job removes expired data. When you delete a site, its payments, events, sessions and visitor profiles are removed. See [retention](https://docs.crispstats.com/privacy/data-collected.md#retention) for the exact rules.

## Requests from individuals

Under the data processing agreement, CrispStats passes a request from one of your visitors to you rather than answering it directly. With the default setup there is no stored identifier that points to a person, so there is usually nothing to look up. If you use `identify()`, the events and profile linked to that person carry the user id you sent.

## Contacts

| Topic | Address |
| - | - |
| Privacy questions, data processing agreement, signed DPA | `privacy@crispstats.com` |
| Security reports | `security@crispstats.com` |
| Everything else | `hello@crispstats.com` |

## Learn more on crispstats.com

* Glossary: [cookie consent](https://crispstats.com/glossary/cookie-consent) and [cookieless tracking](https://crispstats.com/glossary/cookieless-tracking).
* Article: [do you need a cookie banner for analytics?](https://crispstats.com/blog/do-you-need-a-cookie-banner-for-analytics) This is general information, not legal advice.

## Next steps

> [card] [Data collected](https://docs.crispstats.com/privacy/data-collected.md)
>
> Every field, what is derived and discarded, and how long it is kept.

> [card] [Cookieless tracking](https://docs.crispstats.com/privacy/cookieless-tracking.md)
>
> The daily visitor id in detail.

> [card] [Persistent visitors](https://docs.crispstats.com/privacy/persistent-visitors.md)
>
> What changes when you recognise visitors across days.


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