# Install the tracker

> Plaintext version for LLMs. Canonical HTML: https://askbowtie.com/docs/install/

You've added your site. One line left: paste this tag into your site's HTML `<head>` so it loads on every page, then open your dashboard and check it's live. It's the same one line for every platform.

```html
<script src="https://askbowtie.com/bowtie.js" async></script>
```

No account key, no config. The tag detects your domain on its own. Put it just before the closing `</head>` tag, or anywhere inside the `<head>`.

## Pick your setup

Every method drops the same one line onto every page.

### Plain HTML or a codebase you edit
Static sites, custom templates, any framework.
1. Open the layout/template shared by every page (layout.html, base.html, header.php, or your theme header).
2. Find the closing `</head>` tag.
3. Paste the snippet just before it. Deploy.

React, Vue, Next.js, and other SPAs: put the tag in your root layout head (Next.js app router: app/layout; plain React/Vite: index.html). The tracker follows client-side route changes automatically, so one tag covers every route.

Wix, Squarespace, Webflow: use the built-in custom-code box (Settings, then custom code or code injection), paste into the Head, load on all pages.

### WordPress
Easiest, a header plugin:
1. Install and activate WPCode (or "Insert Headers and Footers").
2. Open WPCode, then Header & Footer.
3. Paste the snippet into the Header section. Save.

Or your theme: add it to header.php just before the closing `</head>` tag (use a child theme). Your own logged-in WordPress browsing is excluded automatically.

### Shopify
1. Online Store, then Themes.
2. On your live theme: three-dots menu, then Edit code.
3. Open theme.liquid, find the closing `</head>` tag.
4. Paste the snippet just before it. Save. It then loads on every storefront page.

### Google Tag Manager
1. Tags, then New.
2. Tag Configuration: Custom HTML, paste the snippet.
3. Triggering: All Pages.
4. Save, then Submit to publish.

### Cloudflare
Zaraz (recommended):
1. Cloudflare dashboard, your domain, then Zaraz, then Tools.
2. Add a tool, choose Custom HTML, paste the snippet.
3. Trigger on all page views. Save and publish.

Zaraz loads the tag off your main thread, out of your critical path, changeable from the dashboard with no code deploy.

## Then check it's working

Once the tag is live, open your askbowtie dashboard (https://askbowtie.com/app) and hit "check my site". It fetches your homepage and confirms the tag is served. Your first visitors start showing up from there.

Not detected yet? Confirm the tag is in your served HTML (View Source, search for bowtie.js), that it's on the page you registered, and that you've deployed. Then check again.

## The honest facts

- Size: a 9.8 KB loader on the critical path. Everything else loads async and never blocks rendering.
- Cookies: none. The tracker is cookieless.
- Privacy: it never captures names, emails, form fields, or the text people click, and it doesn't store visitor IP addresses.
- Your data: each site's data lives in its own database.
- Removal: delete the one line. That's the whole uninstall.

## For AI agents

Building with a coding agent? Hand it this:

```
Add this exact script tag to the shared layout that loads on every page,
just before the closing </head>. Do not add any attributes or change it:
<script src="https://askbowtie.com/bowtie.js" async></script>
```

Once data is flowing, your agent can query it all over MCP: errors, analytics, organic search, and paid.

Starting from zero? Create your account (https://askbowtie.com/login) and add your domain first, then come back here.
