Installing the analytics SDK
How to install, how to tell it worked, when data appears, and what it changes on your site.
How do I install the analytics SDK?#
Open Analytics. Until your first install is confirmed, Install is an item in the Analytics sidebar and the install panel lives on that screen. Once an install is confirmed, the panel sits behind the gear icon in the top right of the Product page. Either way, the panel has a Web app / Website card and a Mobile app card. Some projects have three cards instead, with the web split into Website, for your marketing site, waitlist or homepage, and Web app, where your users log in. Each card has its own status, Installed, Not installed or Waiting. Open the one you are installing, pick your framework, press "Copy prompt" and paste it into your AI builder or coding agent. The ones named on that screen are Claude Code, Cursor, Codex, Lovable, Bolt, v0 and Replit, and the Framework row lists React, Next.js, Vue, Svelte, Astro, Angular and Plain JavaScript for the web, and React Native, Swift, Kotlin and Flutter for mobile. The prompt is not limited to that row: on the web it works with any framework, or plain HTML with no build step. Every card uses the same project key. With three cards, pressing "I've installed" on Website or Web app first asks for your domains, and only those are counted: see "Why does the install ask for my domains?".
If your site is on a website builder, WordPress, Webflow, Wix, Squarespace, Shopify or Framer, the same screen has a line for it under the Framework row, with a link, Open the setup guide. The same step-by-step guides are in this help centre under Analytics install guides, one per builder; on Squarespace, follow the guide for any other website.
What the button copies is not a snippet of code. It is one instruction line that points your builder at our public install guide and carries your own project key, so the builder does the install and reports back.
Then publish your site, open it and click around to generate events, and press "I've installed" within the next half hour, because the check only counts events from the last 30 minutes. If the card then reads Waiting, see "My install card says Waiting. What do I do?".
Should I install analytics on my landing page or on my web app?#
Both, with the same project key, in the same project.
- Start with your landing page. That is where visitors decide, and your short links point to that site.
- Then install on the app where your users log in. It takes the same project key.
With one Web app / Website card, both go through that card and share one tab. If your panel has separate Website and Web app cards, use one for each: Analytics keeps the two apart, each with its own tab and its own list of domains.
Where did Install and Dashboard go?#
The Analytics section of the sidebar holds Overview, Product, Social, Short links and Search, plus Install until your first install is confirmed. Overview shows your website traffic by source on one page, Social your Instagram, TikTok, YouTube, Facebook and Threads accounts and posts, and Search your Google Search numbers from your own Search Console.
After your first install is confirmed, the install details, including the project key and the install check, sit behind the gear icon in the top right of the Product page. Until then, the Install screen has Continue to Product at the bottom, greyed out while every card reads Not installed.
Dashboard is simply called Product now, with the same metrics, summary and funnel. At the top of it there is one tab per surface: Web app / Website, with Add Mobile app next to it until your app is installed. Projects with three install cards have Website, Web app and Mobile app tabs instead. If the Web app tab reads "Sessions from yoursite.com moved to Website.", with your own site's address, those sessions are on the Website tab now: press Open Website to go there, or Dismiss to hide the note. With nothing installed yet, Product has no tabs and shows an Install button instead.
How do I know the install worked?#
Press "I've installed". If a window asks for your domains first, add them and press Save domains: see "Why does the install ask for my domains?". Once events from your live site reach us, the card's status changes from Not installed to Installed. If the check finds no matching event, the card reads Waiting: "You marked this installed, but no events have reached us yet. We'll keep checking." Despite that wording, it does not refresh by itself. Go through "Four things worth checking" on the card, then press Check again. The card also offers "Mark as installed anyway", but Product only fills in from events that reach us, so work through the four checks first.
The important part is that window: the check only counts events from the last 30 minutes, and that is the whole window rather than a rounding. A perfectly good install does not verify if you press the button the next morning, or on activity from yesterday, and the screen does not say why. So publish the site, open it and click around for about 30 seconds, then press "I've installed" within the next half hour.
There is a quicker check you can run yourself. Open your live site and look at the browser console: a working install prints a line like [HeyCatch] SDK v0.8.5 (prod) initialized. If that line is not there, the SDK never loaded. If it reads dev where this one reads prod, the version you have came from our development channel and needs replacing with the plain one.
Why does the install ask for my domains?#
Some projects have separate Website and Web app install cards, and on those HeyCatch counts events only from the domains you list. That keeps test, staging and preview addresses out of your numbers. If your panel has one Web app / Website card, it does not ask for domains and there is nothing to add.
The first time you press "I've installed" on a card with no domains, a window opens: Your website domains on the Website card, Your web app domains on the Web app card.
- Type the domain people really use, for example yoursite.com, and press Add. A full link works too: only the domain is kept, and www is matched for you.
- Add any other live address the same way, up to 20 on a card. A subdomain is a separate address, so yoursite.com does not cover app.yoursite.com. If that is where your users log in, it belongs on the Web app card.
- Press Save domains. The install check then runs.
With no domains on a card that asks for domains, nothing is counted there. One web event is enough. Its $lib must be web or posthog-js. On a card with a domain list, the domain in $current_url must match a listed domain exactly. We ignore www. The card does not refresh on its own. Press Check again to check the last 30 minutes.
Enter the address your browser shows on your live site. If your site lives on your builder's address, such as yoursite.lovable.app or yoursite.vercel.app, that is your live address, so enter it. Leave out staging and preview addresses.
"Use a public domain we can reach" means the entry was a local address, an IP address or a name without a dot. "This is a HeyCatch domain" means you entered one of our addresses rather than your own.
How do I add, change or remove a domain?#
This is for projects with separate Website and Web app install cards. Open the install panel: the gear icon at the top right of Product, or Install in the sidebar if nothing is installed yet. Open the card and press the pencil next to its domains. In the window, add a domain with Add or take one off with its ✕, then press Save domains.
- Removing a domain: its events stop counting, and the window shows about how many sessions from the last 90 days that means. Nothing is deleted, so you can add it back any time.
- Moving a domain: a domain belongs to one card, so adding it on the other card moves it there, with its last 90 days.
- A new domain: if your site moves, add the new address. Events from it are not counted until you do.
- One domain for both: a website and an app on the same domain can't be split, so list it on one card.
My install card says Waiting. What do I do?#
Waiting means the card was marked installed. It reads "You marked this installed, but no events have reached us yet. We'll keep checking." It means the last check found no matching event.
Under it are four things worth checking.
- Is the change live? Lovable, Bolt, v0 and Replit keep edits in a preview until you press Publish or Deploy, and we only see your real app.
- Open your live app in a browser and click around for a few seconds, then check again.
- Did a script or an AI agent do the visiting? Automated and headless browsers are filtered out as bot traffic, so open the app yourself, in a normal browser.
- Still nothing? The card has a line to paste back into your AI builder. It checks your install against our install guide, above all that the installed version is the latest stable one and not a -dev build, because a -dev build sends events to the wrong place.
If you use a beforeSend hook, change the event in place and keep $lib, $current_url and $session_id. See "Why does the install ask for my domains?". The card does not refresh on its own, so press Check again.
The same card has "Mark as installed anyway". It does not make events arrive: Product only fills in from events your site or app sends, so go through the four checks first.
If your card lists domains, check them as well: only events from a listed domain count, so it has to match your browser's address bar, apart from www. To fix one, see "How do I add, change or remove a domain?".
How long before data appears in the dashboard?#
Give it about 30 minutes before the dashboard is worth looking at.
Do not confuse that with the install check, which is immediate but only counts events from the last 30 minutes. Click around your site, verify straight away, then come back to the dashboard about 30 minutes later.
If 30 minutes have passed and it is still empty, ask us here instead of waiting longer. We can see whether any events have ever arrived from your site, and waiting does not fix an install that is not sending.
I installed the SDK but pressing "I've installed" says no events were seen. What is wrong?#
The card then reads Waiting, "You marked this installed, but no events have reached us yet. We'll keep checking.", and it almost always means the check found no matching events from your site in the last 30 minutes. It is about the window the check looked at, not a verdict on your code. See "Why does the install ask for my domains?". Two things cause almost all of these.
- The change is not actually deployed. The SDK only reports from your live site, so an edit you have not published yet produces nothing.
- The check only looks at the last 30 minutes, so a correct install verifies as failed if you press the button on older activity.
A third, rarer one: the site was opened by an automated browser, a testing tool or a coding agent rather than by you. Those visits are filtered out as bot traffic, so nothing arrives.
Do it in this order.
- Publish the site with the SDK on it.
- Open the live site and click around for about 30 seconds.
- Press "I've installed" within the next half hour, or Check again on a card that reads Waiting.
The card does not refresh on its own. When the check finds a matching event, the status turns to Installed. The Waiting card lists the same causes under "Four things worth checking", plus a line to paste back into your AI builder that checks you are not on a -dev build. If your card lists domains, check those too: only events from a listed domain count, so a typo or a missing address looks like no events. The dashboard itself needs about 30 minutes after the first events land.
Does installing the SDK change my build scripts, environment variables, CI or middleware?#
No. No environment variables, no build script changes, no CI changes, no middleware.
What it touches: your package manifest, one init call at your client entry point, and optionally identity calls in your sign-in and sign-out paths. Deployment config is touched only if you opt into short links, which adds a single redirect rule. The SDK adds three headers, X-HeyCatch-Session-Id, X-HeyCatch-Window-Id and X-HeyCatch-Distinct-Id, to requests your page sends to its own address. Other hosts get them only if you list them in tracingHosts, and a host you list has to allow those three headers in its CORS settings, or the browser blocks your page's requests to it. They go to your own server, not to us, and they are added even while capturing is off, with ids that change on every page load.
Will the analytics snippet slow my page down?#
It loads asynchronously, after the page has rendered, so it does not block anything on the page.
Can I run Google Analytics and HeyCatch analytics at the same time, or will events be double counted?#
You can run both. They are separate systems and do not interfere with each other, so nothing is double counted between them. The one thing to avoid is installing the HeyCatch snippet twice on the same site, because that does duplicate events.
Is HeyCatch still worth using if I do not install the analytics SDK?#
Yes. Without the SDK there is no site analytics: no Product dashboard, funnels or recommendations, no users or session timelines, and no short links or channel attribution. Search and Social do not come from the SDK: they read from your own Google Search Console and your connected Instagram, TikTok, YouTube, Facebook and Threads accounts. Catches on Reddit, X and Threads, and the videos for Instagram, TikTok, YouTube and Facebook, all run without the SDK, off your connected accounts and your live site.
I do not want tracking inside my product. Can I install the SDK on my landing page only?#
Yes. Put it on the landing page and leave the product itself untouched. That is where a lot of the signal you care about lives anyway: who arrives, what they read and where they drop off before they ever sign up.