← Back to the blog Tracking and consent

LinkedIn Insight Tag: how to install it and check it still works

LinkedIn Insight Tag: how to install it and check it still works

The LinkedIn Insight Tag is a JavaScript snippet that reports visits on your site to LinkedIn, so Campaign Manager can attribute conversions, build retargeting audiences and show the professional demographics of your visitors. You install it once per site, in the page template or through Google Tag Manager, and it identifies the ad account with a numeric partner ID.

For a B2B client running LinkedIn Ads, the rest of the account depends on it. When the tag disappears, conversions drop to zero and the ad account doesn't say why.

What the tag does for a LinkedIn Ads account

Conversion tracking is the main reason to install it. You define a conversion in Campaign Manager, for example a visit to a thank-you page, and LinkedIn credits it to the campaign the member saw or clicked. The same data feeds website audiences for retargeting, and the website demographics report, which breaks visitors down by job function, industry and company size for the members LinkedIn can match.

What the code looks like

The standard snippet declares your partner ID and loads a script from LinkedIn's CDN:

<script type="text/javascript">
_linkedin_partner_id = "1234567";
window._linkedin_data_partner_ids = window._linkedin_data_partner_ids || [];
window._linkedin_data_partner_ids.push(_linkedin_partner_id);
</script>

It continues with a loader that injects https://snap.licdn.com/li.lms-analytics/insight.min.js, and a <noscript> image pointing to px.ads.linkedin.com for browsers without JavaScript. Copy the full snippet from Campaign Manager rather than retyping it, and add it to every page before the closing </body> tag.

Note the partner ID. It's how you tell whether the tag on a site belongs to your client's account or to a previous agency's.

Installing it through Google Tag Manager

GTM has a built-in tag type called LinkedIn Insight. Create the tag, paste the partner ID and fire it on all pages, or on the consent trigger your CMP setup uses. It's usually the tidier option, because the tag follows the same consent rules as GA4 and the other pixels. Pick one method, not both.

For conversions with no thank-you page, such as a form that submits in place, fire LinkedIn's event-specific call on the event: window.lintrk('track', { conversion_id: 1234567 });.

How to check the tag is active

Campaign Manager shows whether LinkedIn is receiving data from the tag, but not in real time, so use the browser for a quick check. Open DevTools, go to the Network tab, filter on linkedin and reload. You should see insight.min.js load from snap.licdn.com, then requests to px.ads.linkedin.com. Disable your ad blocker first, since most of them block this script. To test a conversion, complete the action yourself and look for a new request to px.ads.linkedin.com right after it.

Consent and the cookie banner

The Insight Tag sets advertising cookies, so on UK and EU sites it normally sits in the marketing category of the CMP and loads only after consent. Test both paths, accepting and refusing. A misconfigured banner can block the tag for everyone, including visitors who say yes, so if conversions fall right after a banner change, look there first. Our guide to cookie banner monitoring covers how CMP swaps go wrong.

What usually breaks it

None of these show an error on the page:

Catching it when it disappears

Checking the network tab by hand doesn't scale across client sites and deploys. Deltio reads the page source of each monitored URL, detects the LinkedIn Insight Tag along with GA4, GTM, Meta Pixel and others, and sends an email or Slack alert when a tag appears or disappears. If LinkedIn runs inside GTM, Deltio sees the container instead and alerts if it goes missing or its ID changes, but it can't see which tags are published inside it. It also flags a change of CMP on the home page.

It doesn't confirm that conversions fire or that Campaign Manager receives them, so repeat the manual test after any change to forms. More on this in marketing tag monitoring and how to check GA4 is installed.

Starter costs £24 a month, £20 billed annually, and you can try it free for 14 days.

Frequently asked questions

Is the LinkedIn Insight Tag free?
Yes. Installing the Insight Tag costs nothing and it works with any LinkedIn ad account. You pay only for the campaigns you run, and the tag supplies their conversion, retargeting and demographic data.
Where do I find my LinkedIn partner ID?
In Campaign Manager, in the Insight Tag section of the ad account, where you also copy the snippet. On a live site you can read it in the page source: it is the value assigned to _linkedin_partner_id in the tag's script.
Can one Insight Tag be used on several websites?
Yes. The same tag and partner ID can be installed on more than one domain, and LinkedIn collects the data from all of them in the same ad account. Conversions and audiences can then be limited to specific URLs.
Why does LinkedIn show fewer conversions than my form tool?
Some visitors refuse cookies, block the script with an ad blocker or can't be matched to a LinkedIn member, and LinkedIn only attributes conversions it can link to someone who saw or clicked an ad. A gap is normal; a sudden drop to zero usually means the tag or its trigger has stopped working.
Does Deltio check that LinkedIn conversions are tracked?
No. Deltio detects whether the Insight Tag snippet is in the page source and alerts you when it appears or disappears, and when the GTM container goes missing or changes ID. It doesn't check events, consent signals or whether Campaign Manager records conversions.