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

# Explore custom events and their properties in CrispStats

> Use the CrispStats Events screen to see every custom event in a date range, sort them, open property breakdowns and copy snippets to send new events.

The **Events** screen lists every custom event your site sent in the selected range, with counts, unique visitors and trend, and opens any event into a breakdown of the property values sent with it. The same screen holds your [goals](https://docs.crispstats.com/dashboard/goals.md) and a panel with copyable snippets for sending events.

Open it from the sidebar under **Analytics**, **Events**, press `g` then `e`, or select **All events** on the overview's **Events and goals** card. The screen follows the date range, comparison and filters in the top bar.

## Send your first event

If the site has not sent an event in the range, the table is empty and the **How to track events** panel opens by itself. Add one of its snippets to your site, trigger the action, and the event appears here.

```html HTML attribute theme={"theme":{"light":"github-light","dark":"github-dark"}}
<!-- A click on the element, or anything inside it, sends the event.
     Each data-cs-prop-* attribute becomes a property. -->
<button data-cs-event="signup" data-cs-prop-plan="pro">
  Start free trial
</button>
```

```js JavaScript theme={"theme":{"light":"github-light","dark":"github-dark"}}
// Props are flat: strings, numbers, booleans or null.
crispstats("signup", { plan: "pro" });
```

```js Revenue theme={"theme":{"light":"github-light","dark":"github-dark"}}
// Amount in minor units (cents), then an ISO 4217 currency code.
crispstats.revenue(4900, "USD", { plan: "pro" });
```

```html Before the script loads theme={"theme":{"light":"github-light","dark":"github-dark"}}
<!-- Above the script tag. Calls made before it loads wait here and run in order. -->
<script>
  if (typeof window.crispstats != "function") {
    var queue = [];
    var stub = function () { queue.push([].slice.call(arguments)); };
    stub.q = queue;
    ["identify", "revenue", "pageview"].forEach(function (method) {
      stub[method] = function () { queue.push(Object.assign([].slice.call(arguments), { m: method })); };
    });
    window.crispstats = stub;
  }
</script>
```

Use the same name every time the action happens, like `signup`, then add it as a goal to track its conversion rate. See [custom events](https://docs.crispstats.com/track/custom-events.md) and [declarative events](https://docs.crispstats.com/track/declarative-events.md) for the full API.

## The events table

The table lists up to 200 custom events, busiest first.

| Column | What it shows |
| - | - |
| **Event** | The event name. |
| **Count** | How many times the event was sent in the range. |
| **Visitors** | How many unique visitors sent it. |
| **Change** | The change in count against the comparison period. Shown when comparison is on. Events with nothing to compare against sort to the bottom. |
| **Revenue** | The revenue carried by the event. Shown when any event in the range carries revenue. |
| **Last seen** | How long ago the event was last sent in the range. |
| Trend | A sparkline of the count across the range, in 12 equal slices. |

Select a column header to sort by it. Numbers sort high to low first and names A to Z first; select the header again to flip the order. The sort is kept in the URL as `esort`, for example `?esort=visitors` or `?esort=visitors.asc`. Count, high to low, is the default.

On phones, each event is a stacked row with its count, visitors, revenue and last seen time.

## Break an event down by property

**1. Select an event**

Select a row in the table. The event is stored in the URL as `?event=signup`, so the breakdown can be linked to.

**2. Read the property cards**

Below the table, **Properties of** the event shows one card per property. Each card lists the values sent, with the count of sends for each value and its share of the listed values.

**3. Filter by the event**

Select the event name chip at the top of the panel to filter the whole dashboard to sessions that sent the event. Select it again to remove the filter.

Select the same row again, or the close button, to hide the properties.

Limits on the breakdown:

* Up to 20 properties per event, the most frequent first.
* Up to 20 values per property, the most frequent first.
* Values longer than 200 characters are cut at 200.
* Only flat values count: strings, numbers, booleans and null. An empty string shows as **(empty)**.

If an event has no properties, the panel says so. If the event was not sent in the selected range, it suggests another event or a wider range.

## Next steps

> [card] [Set up goals](https://docs.crispstats.com/dashboard/goals.md)
>
> Turn an event into a conversion with a rate and a value.

> [card] [Send custom events](https://docs.crispstats.com/track/custom-events.md)
>
> The full JavaScript API, property rules and the queue stub.

> [card] [Build a funnel](https://docs.crispstats.com/dashboard/funnels.md)
>
> Chain events and pages into steps and see where people drop off.


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