Verifying Installation
Once the snippet is installed, you'll want to confirm it's actually running on your site. There are four ways: the status badge in Project Settings, the "Check my site now" button on your project dashboard, the A vs B Chrome extension, and a manual check in your browser's developer tools.
The status badge in Project Settings
Go to Project Settings → Snippet. The badge next to "Install snippet" has two states, and it updates by itself while you watch it. There is nothing to refresh: it checks every 5 seconds while the page is in front of you, and checks again the moment you come back to the tab or window from your own site. If it sits unattended for five minutes it pauses and offers Check again.
- "Installed" (green): the snippet has run in a real browser and reported in. It's live. The badge also shows when the first sighting happened.
- "Not detected" (grey): nothing has reported in yet. Either the snippet isn't on a page that has been loaded, or nobody has loaded such a page yet.
How it works, and why private sites are fine
The snippet tells us it's there. On load, before anything else happens, it sends one tiny message containing nothing but your snippet key. That message comes from the browser of whoever loaded the page, which has three useful consequences:
- The badge never needs to reach your site. Nothing crawls or fetches your URL to turn it green, so a staging site, a site behind a login, an internal tool, or anything else that isn't reachable from the public internet verifies exactly as well as a public site. The one time we fetch a page is when you press "Check my site now" yourself, described in the next section.
- You can verify it yourself in seconds. Deploy, open any page with the snippet on it in your own browser, and watch the badge flip. Your own visit counts.
- It doesn't wait for consent or for an experiment. The message carries no visitor data, so it's sent even for visitors who decline tracking, and it doesn't need a running experiment to fire.
If the badge is still grey a few minutes after you've opened a page yourself, the snippet isn't loading. Work through the checks below.
If your site is reporting in with a key that belongs to a different project, the install card on your project dashboard says so by name, along with which key to use instead. It is the most common reason a badge stays grey on a site that is otherwise installed correctly.
Flag projects prove their install a different way: the SDK checks in after it loads its configuration, and the Environments page shows a connection status per environment. See SDK Installation.
Check my site now
While an install is still unverified, your project dashboard shows an install card (the same one as the last step of onboarding) with a Check my site now button. Press it and we fetch one page of your site, once, and tell you what's in the HTML we got back. Nothing on your site is changed, and nothing runs on a schedule: one press, one look.
Use it when the badge is grey and you want to know whether the tags actually made it into your deployed pages, without opening DevTools.
It answers one of these:
- Both tags are there, with the right key. The install is correct. If the badge is still grey, open the page in a browser once so a real visit can report in.
- The loader tag is there, the first tag is missing. Experiments will run, but visitors can see the original content for a moment before a variation applies. Add the first tag above the loader.
- The first tag is there, the loader tag is missing. Nothing runs. Paste both tags, loader second.
- Your page is using a different key. We name the project the key belongs to when it's one of yours, so you know which one to swap.
- We found a tag but couldn't read its key. The loader is there without a readable key, usually because it's served from a rewritten path or a tag manager dropped the attribute. Compare it with the tags on the card.
- No A vs B tag in the page we fetched. Neither tag is in the HTML your server
returned. Paste both into the
<head>and deploy. - We could not read your page. You get the reason: the site didn't answer in time, the address didn't resolve, the page needs a login, it answered with an error status, it redirected too many times, or it didn't return a web page at all.
Two things it can't do, both by design:
We read the HTML your server sends. If your pages are assembled in the browser and add the tags at runtime (some single-page apps do this through a tag manager), the tags won't be in what we fetched even though your install is perfectly fine. Open a page in your own browser once and trust the badge instead.
A staging site, an intranet, or anything behind a login can't be read from the outside, so this check will report that it couldn't reach the page. That is not a problem with your install: the badge above still proves it from a real browser visit, which is why it remains the answer that matters.
You can only check pages on your own site: the address comes from the site URL on the project, so set that first in Project Settings if the button tells you it's missing. Checks are limited to a few per minute per project.
Chrome extension (fastest per-page check)
The A vs B Chrome extension instantly detects whether the snippet is running on the current page. Install it from the Chrome Web Store and open your site. The extension icon shows a green indicator if the snippet is detected, or grey if it isn't.
Use it when you need to know about one specific page, which the badge can't tell you: the badge answers "has the snippet run anywhere on this project", not "is it on this URL".
The extension is also used for local development with the CLI: it connects to
the avsb dev server and lets you preview variation changes live. See
Local Development for details.
The extension is currently under review by Google and may not appear in search results yet. Use the direct link above, or download it directly and load it as an unpacked extension.
Manual check using browser DevTools
Open your site in a browser and use the built-in developer tools to confirm the snippet loaded. The correct install is two tags: a stub and the async loader:
<script>window.avsb=window.avsb||{};window.avsb.q=window.avsb.q||[];window.avsb.ready=window.avsb.ready||function(f){window.avsb.q.push(f)};window.avsb.on=window.avsb.on||function(n,f){var t=['on',n,f];window.avsb.q.push(t);return function(){t[0]=null}};window.avsb.consent=window.avsb.consent||{set:function(s){window.avsb.q.push(['consent.set',s])},get:function(){return{}}};window.avsb.track=window.avsb.track||{};['event','segment','purchase','cart'].forEach(function(m){window.avsb.track[m]=window.avsb.track[m]||function(a,b){window.avsb.q.push(['track.'+m,a,b])}});(function(){window.avsb._t0=Date.now();window.avsb._df=fetch('https://cdn.avsb.cloud/YOUR_SNIPPET_KEY/datafile.json').catch(function(){});var d=document,e=d.documentElement,s=d.currentScript,a=s&&s.getAttribute('data-avsb-timeout'),t=a==null?3000:+a;if(!(t>0)||window.avsb.version)return;e.style.opacity='0';e.style.pointerEvents='none';window.avsb._t=setTimeout(function(){e.style.removeProperty('opacity');e.style.removeProperty('pointer-events')},t)})();</script><script src="https://cdn.avsb.cloud/snippet.js?id=YOUR_SNIPPET_KEY" data-avsb="YOUR_SNIPPET_KEY" async></script>Copy yours from Project Settings → Snippet, which always has your real key filled in already. Quick Install explains what each line does.
Open DevTools
In Chrome or Edge, press F12 or right-click the page and choose
Inspect. In Firefox, press F12. In Safari,
enable the Develop menu in preferences, then choose
Develop → Show Web Inspector.
Check the Network tab
Click the Network tab and reload the page with DevTools open.
In the filter box, type snippet.js. You should see a request
to cdn.avsb.cloud/snippet.js with a status of 200.
If nothing appears, the snippet tag isn't in your HTML.
Check the Elements tab
Click the Elements tab (Inspector in Firefox). Press
Ctrl+F (or Cmd+F on Mac) to search the HTML, and look
for avsb. You should find a tiny inline stub script followed by
a loader tag carrying data-avsb="YOUR_SNIPPET_KEY", both in the
<head>. If both are missing, the snippet wasn't added to your
template.
Check the Console tab
Click the Console tab and run this:
typeof window.avsb?.getActiveExperiments === 'function'true means the full snippet loaded and is running. false means it hasn't.
Don't test window.avsb on its own: the first tag defines it straight away,
so it is an object even when the second tag never loads. Checking for a method
that only the loaded snippet adds is what tells the two apart.
Common issues
Nobody has loaded the page yet. The badge waits for a real page load. If you've just deployed, open the page yourself once. Nothing else is needed.
Ad blockers. Some ad blockers and privacy extensions block the snippet. That's expected for those users: their experience matches the control (no variation). If the snippet only fails in your own browser, turn off your ad blocker and try again. An ad blocker in the browser you're testing with also blocks the message that flips the badge.
Content Security Policy (CSP) errors. A strict CSP can block the snippet from
loading. In the Console tab, look for errors mentioning "Content Security Policy"
or "Refused to load the script". Add the A vs B domain to your script-src
directive:
script-src 'self' https://cdn.avsb.cloud;You'll also need to allow the data-ingestion endpoint in connect-src. Add
https://app.avsb.cloud to the same directive if you build experiments with the
Visual Editor:
connect-src 'self' https://cdn.avsb.cloud https://ingest.avsb.cloud https://app.avsb.cloud;Without ingest.avsb.cloud in connect-src, the snippet loads but cannot report
in, so the badge stays grey even though the tags are correct. Without
app.avsb.cloud, Visual Editor experiments still run and visitors still see them,
but the browser console may log a policy violation. The Visual Editor also needs
https://assets.avsb.cloud in img-src when you replace images. See
Visual Editor troubleshooting.
Snippet placed in the body instead of the head. It still works in the
<body>, but it loads later, which raises the chance of flicker. Move it to the
<head> for best results.
Wrong snippet key. Double-check that the key in your script tag matches the one in Project Settings → Snippet. With multiple projects, it's easy to copy the wrong one, and a key belonging to another project flips that project's badge instead of this one. You don't have to guess: if your site is reporting in with another key, the install card on your project dashboard names the project it belongs to, and "Check my site now" reports it straight from your page's HTML.
Contact A vs B support at support@avsb.cloud with a link to the page where the snippet should be installed and a screenshot of your Network tab.