LinkJoltAnswers

Getting Started

Can I run an affiliate program without spreadsheets and manual tracking links?

How long does it take to set up an affiliate program with LinkJolt?

What is the difference between tracking links and coupon codes?

Tracking & Attribution

How are free-trial signups tracked, and when does commission count?

How do I install the LinkJolt tracking script?

How do I track affiliate sales without adding code to my checkout?

How does LinkJolt decide which affiliate gets credit for a sale?

How long does an affiliate stay credited after someone clicks their link?

Where do I put the script when my landing page and checkout are on different platforms?

Payouts & Commissions

Approving and rejecting commissions

Can I pay affiliates in their own currency?

Can I reward top affiliates with a higher commission rate?

Does LinkJolt hold my money or process my payments?

How are recurring commissions calculated for subscriptions?

How automatic payouts work, and what the processing fee is

How do I pay my affiliates?

Stripe for tracking and Stripe for payouts are two different things

What commission rate should I offer affiliates?

What does each commission status mean?

What happens to an affiliate's commission when a sale is refunded?

When and how do affiliates actually get paid?

Which countries and currencies can automatic payouts reach?

Why is my commission still pending?

Linkjolt

Sign InStart Free
Tracking & Attribution

How do I install the LinkJolt tracking script?

Copy the one line script tag from the Integration Hub in your dashboard and paste it into the head of every page a visitor can land on. Copy it rather than typing it, because the tag carries your own merchant ID and a wrong ID never raises an error.

4 min read
Updated Sep 4, 2026

Copy the one line script tag from the Integration Hub in your dashboard and paste it into the <head> of every page a visitor can land on. It looks like this:

<script src="https://www.linkjolt.io/api/tracking.js?id=YOUR_MERCHANT_ID" async></script>

Copy it from the Integration Hub instead of typing it out. The id is your own merchant ID and the page fills it in for you. If you run more than one brand, the snippet shown belongs to the brand you are currently switched to, so check the brand name at the top of the sidebar first.

Where the snippet goes

The script has to run on any page an affiliate link can point at, not only your checkout. When a visitor arrives with ?tc=...&aff=... in the URL, the script stores those values in a cookie and in localStorage for 30 days, so the sale is still attributed when they buy days later.

  1. Open Integration Hub, under the Settings heading in the dashboard sidebar.
  2. Pick your platform tab. Step 1 is "Add Tracking Script".
  3. Copy the HTML snippet and paste it inside <head> on every page.
  4. Deploy, then load one of your own pages in a fresh browser session.

Put it in the head of every page, including your homepage, landing pages and blog. A visitor who lands on a page without the script has nothing stored, so a purchase later in that visit cannot be credited to the affiliate's link. Coupon code attribution is the exception, because it needs no script at all.

Next.js and other React frameworks

Use the framework's script component rather than a raw tag. Open "Using React or Next.js?" underneath Step 1 for this version:

import Script from 'next/script' // Add this in your layout.tsx or _app.tsx <Script src="https://www.linkjolt.io/api/tracking.js?id=YOUR_MERCHANT_ID" strategy="afterInteractive" />

Same URL, same merchant ID, and it covers every route because it sits in the shared layout.

Check that it worked

Load one of your pages, open the browser console and run window.linkjolt.getTrackingInfo(). If window.linkjolt is undefined, the tag is not on that page. To test end to end, follow one of your affiliate tracking links through to your site, then check window.linkjolt.referral, which returns a string shaped like tc_..._aff_..._cid_....

The Integration Hub also shows a status line, read when the page loads, so reload it after you test:

  • Not Detected Yet: nothing has reported in for over seven days.
  • Script Detected: the script reported in within the last seven days.
  • Script Active: it reported in within the last 24 hours and your campaigns have clicks from the last 30 days.

Each browser reports in at most once an hour, so test in a fresh session, and expect the status to go quiet again if nobody visits for a week.

A wrong merchant ID never raises an error

Nothing warns you. The script still loads and still stores tracking parameters, so link clicks and sales keep being attributed, but the check-in that carries your ID is discarded and the status sits on Not Detected Yet forever. It happens when you paste a snippet from another account, from a different brand, or from an old note. If you moved to LinkJolt from another affiliate platform, a wrong ID also stops us recognising your affiliates' old links. Re-copy the snippet from the Integration Hub and compare it with what is live on your site.

Editing the ID in your own tag changes the URL, so a correction takes effect on the next page load. The script file itself is cached for a day, so when we release a new version your returning visitors pick it up over the following day or two.

The script is one half of tracking. Your payment processor webhook is the other half, and it is what actually records the sale, so follow "How do I set up affiliate tracking with Stripe?" next. If the script is installed but clicks are not appearing, see "I installed the tracking script but clicks are not being tracked. What now?".

Tags:

trackingsetup

Related questions

Connect Stripe so LinkJolt records your sales

Two routes, and you only need one: approve LinkJolt once on Stripe's own site, which creates no webhook endpoint and no signing secret, or add the LinkJolt webhook endpoint in Stripe yourself and save the signing secret. Both live on Step 3 of the Stripe Checkout tab in Integration Hub.

How long does an affiliate stay credited after someone clicks their link?

30 days. A click stores that affiliate's details in the visitor's browser for 30 days, and a purchase made in that period is credited to them. The window is fixed: there is no setting to change it per campaign or per plan.

Where do I put the script when my landing page and checkout are on different platforms?

Put the script on every page a visitor sees before they pay, starting with the landing page. It only rewrites Stripe Payment Link, Gumroad and Lemon Squeezy links for you, so for any other jump to a different domain you have to carry the tc, aff and cid parameters across yourself.

A sale is missing from my dashboard. What do I check?

A missing sale almost always traces to one of six causes: a webhook signing secret that no longer matches, an endpoint added in Stripe's Test mode, no tracking reference reaching checkout, a purchase outside the fixed 30 day window, an unregistered coupon or an inactive affiliate, or your plan's tracked sales limit. Check them in that order.

Start your affiliate program

Launch in minutes with 0% platform fees. 3-day free trial, cancel anytime.

Start free trialBrowse all questions

Contents

Where the snippet goesNext.js and other React frameworksCheck that it workedA wrong merchant ID never raises an error