A prompt for coding agents
Let your coding agent do the setup.
Copy one prompt into Claude Code, Cursor, Codex, Lovable, Bolt, v0 or Replit. It installs the script in the right file, tracks your key actions as goals, identifies signed-in users and passes the visitor id to your checkout.
14-day free trial · No card required · From $9/month
What the prompt asks for.
Four jobs, in order, each kept to the smallest change that does it.
- Install the script
- The agent works out your framework and adds the tag once, to the shared
<head>:app/layout.tsxwithnext/scriptin Next.js,nuxt.configin Nuxt,src/app.htmlin SvelteKit, the base template in Laravel or Django. - Track 3 to 6 goals
- It looks for the actions that matter, such as signup, trial started or checkout started, and adds a call like
window.supr("signup")right after each one succeeds. - Identify signed-in users
- After login, after signup and when a signed-in session loads, it calls
window.supr("identify")with the user's id, email and name. - Link checkouts to visitors
- It passes the visitor id to Stripe, Polar, Dodo Payments, Paddle or Lemon Squeezy checkouts, or sends payments from your server to the Payment API.
Written with your values.
The prompt under Settings → General → AI agent has your website id, domain and script address filled in, and your additional domains when you have them. The same prompt is shown while you add a website, and in the docs with placeholders.
- Keep every change minimal and leave unrelated code alone
- Load the script as a normal external script: never bundled, inlined or imported
- Don't add pageview calls on route changes, since navigation is already tracked
- Keep API keys in an environment variable and never commit them
What's left for you.
The agent ends with a list: the files it changed, the goal names and when each fires, how the visitor id reaches your checkout, and what you still have to do, such as deploying, connecting your payment provider's webhook and adding an API key to your environment.
Set it up.
Copy the prompt
Open Settings → General of your website, pick the AI agent tab and click Copy prompt.
Paste it into your agent
In Claude Code, Cursor, Codex or your AI builder, in the project you want tracked.
Review and deploy
Read the agent's summary and its changes, then deploy and open your website.
Connect payments
If it linked a checkout, add your provider's webhook in Settings so payments arrive.
How it works, in detail.
The docs page “Set up tracking with a coding agent or AI builder” goes through it step by step.
Limits worth knowing
- The agent edits your code: review its changes as you would anyone else's
- It picks the goals from what it finds in your code; change the calls if you want others
- Connecting your payment provider's webhook is up to you, in SuprAnalytics and in the provider
Questions, answered.
Which coding agents does it work with?
Where do I find the prompt?
Does it change my payment code?
customData for Paddle.js, as custom data for Lemon Squeezy, or as client_reference_id on Stripe Payment Links. Polar and Dodo links and Paddle buttons need nothing.What if my app takes no payments?
Will my localhost visits be tracked?
supr-allow-localhost, so development visits stay out until you switch on Track localhost in Settings → General.More features
- One script, every frameworkA line in the head of your pages, with guides for every common framework and builder.Open
- MCP serverAsk Claude, ChatGPT or any MCP client about anything on your dashboard in plain words.Open
- CLISee every website's traffic, revenue, uptime and what to fix from your terminal.Open
- REST APIRead every report, and send goals, payments and crawler hits from your server.Open
- Script configurationEvery supr-* attribute and window.supr() call: goals, identification and more.Open
- User identificationPut a name and an email on a visitor, so journeys and chats show who they are.Open
- Tracking parametersUTM tags and ref links, and how channels are worked out from them.Open
See it on your own website.
Every feature is on every plan, with a free trial and no card.
14-day free trial · No card requiredPricingHow it worksAll features