Installing the pixel
Add Primer's website pixel to your site by pasting the snippet or using Google Tag Manager.
Primer's website pixel identifies the companies and people visiting your site so you can build audiences and track conversions from that traffic.
The snippet
Add this script to your site, replacing {CLIENT_ID} with your organization's client ID (shown in Primer when you set up the website pixel):
<script async src="https://web-script.api.sayprimer.com/primerAnalytics.js?clientId={CLIENT_ID}"></script>Where to put it
Directly in your HTML — paste the snippet into the
<head>of every page.Google Tag Manager — add it as a Custom HTML tag that fires on all pages.
Content Security Policy
If your site sets a Content Security Policy, add these domains to the matching directives — if any is missing, the browser blocks the pixel and no traffic reaches Primer:
script-src https://cdn.jsdelivr.net https://tags.fullcontact.com— the pixel loads FingerprintJS (fromcdn.jsdelivr.net) and FullContact (tags.fullcontact.com) to identify visitors.connect-src https://web-script.api.sayprimer.com— the pixel sends events here.
If the pixel isn't being blocked by CSP
A too-strict CSP fails silently to you but loudly in the browser: the page keeps working, but you'll see Content Security Policy violation errors in the browser's developer console, and Primer stays Not connected because events never leave the page. If connection status won't turn green after installing:
Open your browser's developer console on a page with the pixel and look for CSP violations naming
web-script.api.sayprimer.com,cdn.jsdelivr.netortags.fullcontact.com.Add whichever domain is being blocked to the directive named in the error (
script-srcorconnect-src), then reload.
After installing, check that Primer is receiving traffic — see Pixel connection status.
Last updated