HeyCatch Help heycatch.ai

Install analytics on any other website

Use this guide if your site is not on a platform we have a guide for, Squarespace included, or if you edit your site's HTML directly.

Before you start

  1. You need a way to add code to the head of every page. Most website tools call this custom code, header code or head code.
  2. You need your HeyCatch project key. It starts with hck_pk_.

1. Find your project key

Your project key starts with hck_pk_. Before your first install is confirmed it sits on the Analytics, Install screen in the sidebar; once an install is confirmed it sits behind the gear icon in the top right of the Product page. Press Copy prompt, paste the text into a note and copy just the key, from hck_pk_ to its last character. If a full stop follows the key, leave it out.

2. Copy this code

Replace YOUR_PROJECT_KEY with your key and keep the quotes:

<script type="module">
  import { analytics } from 'https://esm.sh/@heycatch/sdk@0.8.0';
  analytics.init({
    projectKey: 'YOUR_PROJECT_KEY',
    requestBatching: false,
    install: { framework: 'web', agent: 'other' },
  });
</script>

Keep requestBatching: false if every click on your site loads a new page, which is how most website builders work. Without it visits from iPhones get lost.

3. Add it to your site's head

Paste the code inside the head of every page. If your tool has one header code box for the whole site, use that, so you paste it only once.

If you use an AI builder such as Lovable, Bolt, v0 or Replit, you do not need this guide: use the prompt on the Install screen instead.

4. Publish your site

Publish or deploy the change, however your tool does it. The code runs only on the live site.

5. Visit your live site

Open your live site in a normal browser and click around for a few seconds. Visits from bots, scripts and automated browsers are filtered out, so it has to be you, clicking.

6. Check in HeyCatch

Back in HeyCatch, on the screen where you copied the prompt, press "I've installed" within the next half hour. The check only counts events from the last 30 minutes, so do it straight after your visit.

Not seeing events?

  1. Did you publish? Saving is not always the same as going live.
  2. Is the key right? It starts with hck_pk_ and sits inside the quotes, with no extra spaces.
  3. Is it on every page? Code on one page only tracks that page.
  4. Does your site set a Content Security Policy? If so, it must allow https://esm.sh and https://in.heycatch.ai for scripts, and https://in.heycatch.ai for connections. If you do not know what this is, you almost certainly do not have one.

Still stuck? Write to us in the chat and we will look at your site.

Short links are a separate step. Each link needs one redirect rule on your site, from /i to /?utm_campaign=i for each letter you use. On Squarespace, the redirect tool may not accept the & in that address. If the rule does not save or does not work, share the full link instead, https://yoursite.com/?utm_campaign=i, which is counted the same way. The Short links article explains the rule.

Last updated 2026-10-05 · support@heycatch.ai