Analytics Lab / Instrumentation

LinkedIn Insight Tag sandbox

The Insight Tag records page views and conversions for LinkedIn ads. Each conversion is created in Campaign Manager, which assigns it a numeric ID. The page then fires lintrk('track', { conversion_id: ID }) when the action happens. Use the controls below to see the call each interaction would make.

The tag call only needs conversion_id. The extra fields on each card show the context the page has at that moment. A fixed conversion value can be set on the conversion in Campaign Manager. Per-event value and currency, hashed identifiers and offline events are sent server side through the Conversions API.

Partner ID
LINKEDIN-ID
Endpoint
https://px.ads.linkedin.com/collect

Tracked interactions

Each card fires one lintrk('track') call. LinkedIn reports conversions for ad attribution, so in production you would tag business outcomes such as leads, sign-ups and purchases. The later sections apply the same pattern to smaller interactions.

Lead generation

Buttons and forms that create leads.

Conversion ID: 1

Demo request

The main call to action on a landing page.

Interaction
click
Label
Request a demo

Not fired yet.

Payload
 

Conversion ID: 4

Sales call booking

Fires when a visitor books a sales call. Compare it with offline conversions sent through the Conversions API.

Interaction
click
Value
0 (lead)

Not fired yet.

Payload
 

Conversion ID: 3

Lead form

A short lead form. The form values are added to the payload on submit. The hashed email is a placeholder; the Conversions API expects a SHA-256 hash.

Interaction
submit
Company size
From form value

Not fired yet.

Payload
 

Content engagement

Mid-funnel interactions used to build retargeting audiences.

Conversion ID: 2

Pricing page link

Tracks a click to the pricing page. Navigation is blocked in this demo so you can read the payload.

Interaction
click
Destination
/pricing
View pricing
Payload
 

Conversion ID: 5

Video 50% milestone

Fires when a visitor watches half of the product overview video. Useful for a retargeting audience of engaged viewers.

Interaction
click
Threshold
50% completion

Not fired yet.

Payload
 

Conversion ID: 6

Newsletter sign-up

A newsletter sign-up form. The payload includes a hashed email and the selected preferences.

Not fired yet.

Payload
 

Commerce

Cart, checkout and purchase events.

Conversion ID: 7

Add to cart

Fires when a product is added to the cart. Value and currency are shown for reference.

Not fired yet.

Payload
 

Conversion ID: 8

Checkout start

Fires when a visitor starts checkout. Compare with purchases to measure drop-off.

Not fired yet.

Payload
 

Conversion ID: 9

Purchase

Fires on the order confirmation page. The order ID lets you match the event to backend orders and deduplicate it against a Conversions API event.

Not fired yet.

Payload
 

Interface interactions

Preference changes, modals, help text and ratings.

Conversion ID: 10

Theme toggle

Records a light/dark theme change. The payload includes the previous and next state.

Interaction
click
Dynamic
toggle state

Current theme: Light

Theme set to light.

Payload
 

Conversion ID: 11

Email consent

Records an email preference change with its consent state.

Interaction
change
Fields
preference + consent
Payload
 

Conversion ID: 12

Webinar modal

Opening the modal fires conversion 12. Dismiss fires 20 and Register fires 21. Only the registration would normally be a LinkedIn conversion.

Interaction
click
Actions
open / dismiss / register

Modal closed.

Payload
 

Conversion ID: 13

Inline help

Shows or hides a pricing FAQ answer. The payload records the content ID and whether it is visible.

Interaction
click
Dynamic
visible / hidden

Answer hidden.

Payload
 

Conversion ID: 14

Article rating

Records a 1–5 rating for a help-center article. The payload includes the rating and the scale maximum.

Interaction
change
Scale
1–5

No rating yet.

Payload
 

Sharing, scroll depth and errors

Copy, share, print, scroll depth and error events.

Conversion ID: 15

Copy link

Copies the article URL to the clipboard and records the URL in the payload.

Not fired yet.

Payload
 

Conversion ID: 16

Share to X

Records a social share. Change channel for other networks.

Not fired yet.

Payload
 

Conversion ID: 17

Print article

Records a print or save-to-PDF action.

Not fired yet.

Payload
 

Conversion ID: 18

Scroll depth

An IntersectionObserver fires once when the marker below is fully in view.

Scroll marker: fires once at 90% depth

Waiting for scroll.

Payload
 

Conversion ID: 19

Non-fatal error

Records a recoverable error, such as a checkout request timing out.

No errors logged.

Payload
 

Insight Tag snippet

The base tag sets _linkedin_partner_id and loads insight.min.js asynchronously. Page views are recorded automatically. Calls made before the script loads are queued in lintrk.q.

<script type="text/javascript">
  _linkedin_partner_id = 'LINKEDIN-ID';
  window._linkedin_data_partner_ids = window._linkedin_data_partner_ids || [];
  window._linkedin_data_partner_ids.push(_linkedin_partner_id);
</script>
<script type="text/javascript">
  (function(l) {
    if (!l) {
      window.lintrk = function(a, b) { window.lintrk.q.push([a, b]); };
      window.lintrk.q = [];
    }
    var s = document.getElementsByTagName('script')[0];
    var b = document.createElement('script');
    b.type = 'text/javascript'; b.async = true;
    b.src = 'https://snap.licdn.com/li.lms-analytics/insight.min.js';
    s.parentNode.insertBefore(b, s);
  })(window.lintrk);
</script>

An event-specific conversion is created in Campaign Manager and fired from the page with its ID:

window.lintrk('track', { conversion_id: 1234567 });

Server-side events go to the Conversions API instead. They reference the same conversion rule, carry hashed user identifiers and an optional conversionValue, and can be deduplicated against tag events with a shared event ID.