# Know when your site breaks for someone.

Before they write to you. Error tracking records the uncaught JavaScript errors and unhandled promise rejections your visitors run into, grouped by message. Each group shows the pages and browsers it hit and how many visitors saw it, in the same dashboard as your traffic.

Try it on sample data: [Error tracking in the demo](/app/demo/errors)

## Grouped, counted, ranked

The same error from a thousand visits is one row, not a thousand. Each group shows its type and message, how many times it happened, how many visitors it reached, when it was first and last seen, and a small chart of its occurrences over time.

A new group is marked as new, so a deploy that introduces a bug stands out the same afternoon. Mark a group resolved or ignored to keep the list about what still needs work.

- The pages each error happened on, and the browsers that threw it
- A sample stack trace for each group
- The share of sessions with no error at all, as one number to watch

## Enough detail to fix it

Open a group to see the message, a stack trace from one occurrence, the pages it hit most and the browsers involved. An error that only happens in one Safari version on one template usually explains itself.

Because errors sit beside your analytics, you can see what a bug costs: whether those visitors left, and whether the page converts worse while it is there.

## Small by design

The errors module is part of the same script, behind one attribute. Each distinct error is sent once per page load, ten per page at most, so a loop that throws on every frame cannot flood your data or your visitor's network.

Cross-origin "Script error." messages, which carry no information, and failed resource loads are skipped. Stacks can include URLs from your own site, so keep secrets out of them as you would anywhere.

## One attribute. No SDK to wire up.

1. **Turn on the module.** Add data-errors to the script tag. It listens for uncaught errors and unhandled rejections.

```html
<script
  defer
  data-site="cs_pk_your_site_key"
  data-domains="example.com"
  data-errors
  src="https://in.crispstats.com/d.js"
></script>
```

2. **Open Errors.** Groups appear as errors happen, with the newest and the most frequent easy to tell apart.

3. **Get an alert for new ones.** Set an alert for a new error or a spike in errors, sent to email, Slack, Discord, Telegram or a webhook.

## Frequently asked questions

### Is this a replacement for a full error monitoring tool?

For many small sites, yes. It covers uncaught browser errors with grouping, stacks and alerts. It does not capture server errors, source maps, breadcrumbs or session replays. If you need those, keep your dedicated tool and use this as an extra signal.

### Do errors count toward my plan's events?

No. Only pageviews and custom events count. Errors cost nothing extra on any plan.

### Can errors contain personal data?

An error message or stack can contain whatever your code puts in it, including URLs from your own site. The script sends the message, source, line, column and stack, and nothing else from the page.

### Why do I not see some errors?

Errors from scripts on another origin arrive as "Script error." with no detail and are skipped. Errors caught by your own code never reach the window, so they are not reported.
