> AI agents: this is one page of nextanalytica's docs. The full index for agents: https://nextanalytica.app/llms.txt

# TanStack Start custom events

> Send custom events from a TanStack Start app with @nextanalytica/tag: sign-ups, demo requests and conversions your agent reads by channel.

Updated: 2026-12-01

In TanStack Start, send custom events with `track` from `@nextanalytica/tag` in a component's event handler. Mark the events that matter as conversions.

## How does it look?

```tsx title="src/components/SignupButton.tsx"
import { track } from "@nextanalytica/tag";

export function SignupButton() {
  return <button onClick={() => track("signup_started", { plan: "team" })}>Start free</button>;
}
```

## What about server functions?

These functions only run in the browser: on the server they do nothing, so call them from code that runs in the browser. For what your server confirms, send a server event with a server key: see [Revenue tracking](/docs/learn/revenue-tracking#what-about-orders-the-browser-never-sees).

## What can you ask your agent?

- "Which events happen most this week?"
- "What's the sign-up rate by channel this month?"

## Next steps

- [TanStack Start analytics](/docs/platforms/tanstack)
- [Custom events](/docs/tracking/custom-events)

Canonical address: https://nextanalytica.app/docs/platforms/tanstack/events
