Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.tracelit.io/llms.txt

Use this file to discover all available pages before exploring further.

React
npm install @tracelit/tracker
Add init() once at the top level of your app — main.tsx or App.tsx works great.
// src/main.tsx  or  src/App.tsx
import { init } from '@tracelit/tracker'

init({ token: 'YOUR_TOKEN_HERE' })
That’s it. Tracelit handles SPA route changes automatically via history.pushState — no router config needed.
Using authentication? Call identify() after login to link sessions to real users. See Identify users.

What’s tracked automatically

Once init() runs, all of this starts working with zero extra code:
  • Page views (including client-side route changes)
  • Clicks, rage clicks, and scroll depth
  • Session replay
  • JavaScript and API errors
  • Performance metrics (LCP, FCP, TTFB)
  • Live visitor count

Install with AI (Bolt, Lovable, Replit)

Bolt logo

Lovable logo

Replit logo
Install Tracelit in my React project.
Use @tracelit/tracker and initialize it in src/main.tsx (or App.tsx) with:
init({ token: 'YOUR_TOKEN_HERE' })
Make only minimal changes, then show changed files and a quick verification checklist.

What’s next?

Identify users

Link sessions to real users after login.

Feature tagging

Mark flows like checkout or onboarding in replays.