Add my own analytics or chat tool to my site

If you already use Google Analytics, Microsoft Clarity, or a chat tool like Intercom, you don't have to give it up to move to Bernard. Tell your AI which one and give it your id, and it goes on every page — same as it would if you'd pasted the code in yourself, minus the pasting.

How it works

  1. Say which tool, and give your id. For example: "Add Microsoft Clarity to my site, my project id is 3t0wlogvdz." Every supported tool has an id like this, shown somewhere in that tool's own dashboard.
  2. Your AI checks it looks right and puts it on. If the id doesn't match the shape that tool uses, you'll be told, with where to go and look again — rather than something broken quietly going live.
  3. It starts working within about a minute. No approval, no publish button — it isn't a change to any page, so there's nothing to review.

What's supported today

Analytics — Google Analytics 4, Microsoft Clarity, Plausible, Fathom.

Chat — Intercom. More chat tools may be added over time — if you use something else, ask and it'll be considered.

Why this works differently from everything else

Every other change your AI makes to your site — new text, a new page, a new photo — goes onto a private draft first, and only appears for visitors once you approve it. Working code, on the other hand, is never allowed onto any page at all, draft or live — that's a safety rule with no exceptions, because a page is the one place a bad script could do real damage.

Analytics and chat tools need working code to function, so they're handled a different way entirely: you give the tool and the id, and that's switched on separately from your pages, the same way for every site. Nothing gets pasted in, so there's nothing for a later edit to accidentally delete either — add a new page next month, and your analytics is already watching it.

Switching or removing one

Changed analytics providers, or moved to a new Clarity project? Ask again with the new id — it replaces the old one, no need to remove it first. Don't want a tool any more? Ask to remove it, and it's gone within about a minute.

A word on ad-tracking pixels

Meta Pixel, Google Ads, TikTok and LinkedIn tracking aren't on this list yet. Those track visitors for advertising, which brings consent rules the others don't — Bernard doesn't yet have a way to ask your visitors' permission for that, so it isn't offered until it does.

The prompt

Add [Google Analytics / Microsoft Clarity / Plausible / Fathom / Intercom] to my site. My id is [paste it here].

The [bracketed] parts are yours to fill in. First time? Connect bernard to your AI over MCP — a one-time setup in bernard → your site → Use your own AI — then paste the prompt above.

Questions people ask

Do I need a developer to add Google Analytics or a chat widget?
No. Tell your AI which tool you use and give it your id — the number or code the tool gave you when you signed up — and it goes on every page of your site. No code to paste, no file to edit.
Which tools are supported?
Analytics: Google Analytics 4, Microsoft Clarity, Plausible and Fathom. Chat: Intercom. That's the current list — if you use something else, ask and it'll be considered; more chat tools may be added over time.
Why can't I just paste the tracking code myself?
Bernard won't let anyone — including its own AI — paste working code into your pages. That's a safety rule, not a limitation: it's what stops a stray or malicious script from ever ending up on your site. Analytics and chat tools are the one deliberate exception, added a different, safer way — see below.
Where do I find my id?
In the tool's own dashboard — each one has a settings or setup page that shows it. If you're not sure where, ask your AI to add the tool and, if what you give it doesn't look right, it'll tell you exactly where to look.
Do I need to publish for it to start working?
No. It isn't part of your page — it's switched on separately, the moment you ask — so it starts working within about a minute, and it's already there for pages you add later. Nothing to approve, nothing to publish.
Can I switch to a different account, or take it off?
Yes to both, any time. Ask to switch to a new id for the same tool and it replaces the old one. Ask to remove a tool and it comes off — your site keeps working exactly as before, just without that one thing counting or watching.

You might also want to…