Every affiliate eventually hits the same wall: the dashboard shows total clicks and total sales, but nothing about which clicks turned into which sales. The Facebook ad or the email blast? The blue button or the red one? Without an answer, you’re optimizing blind. Sub IDs are how you get the answer.
I’ve used sub IDs as an affiliate to find which traffic source was worth my time, reviewed sub ID reports as an affiliate manager deciding which partners to back, and built the tracking infrastructure that records them. This guide covers what sub IDs are, how they work, and how to use them without turning your reports into an unreadable mess.
What are sub IDs in affiliate tracking?
A sub ID (short for sub identifier) is a small piece of text attached to your affiliate link to label where a particular click came from. The network or tracking platform stores that label alongside the click, and if it later turns into a sale, the sub ID rides along with the conversion report — giving you detail the base link can’t provide on its own:
- The traffic source (Facebook, Google Ads, an email newsletter, a YouTube description).
- The specific ad, creative, or piece of content that drove the click.
- The audience segment, placement, or keyword behind that click.
Sub IDs are entirely custom text, which is both the appeal and the risk: you can label a click anything you want, but nothing stops you from being inconsistent about it. If you haven’t worked through the fundamentals of how clicks become commissions — cookies, postbacks, attribution — our guide to how affiliate tracking works is the right place to start before layering sub IDs on top.
Why affiliate sub IDs matter
A base tracking link tells you that traffic converted. Sub IDs tell you which traffic converted, which is a completely different kind of information. In practice, sub IDs deliver four things that flat reporting can’t:
- Granular insight. See performance down to an individual ad, landing page, or keyword, instead of one blended number for the whole campaign.
- Faster identification of winners. When one sub ID converts noticeably better than the rest, you know where to put more budget.
- Real A/B testing. Tag two creatives or landing pages separately and let the data — not a hunch — decide which one wins.
- Better use of time and money. Once you see which channels and creatives actually produce sales, you stop spreading effort evenly and start doubling down on what works.
None of this replaces the core metrics that determine whether a program is worth your time — conversion rate, earnings per click, average order value. Sub IDs are how you break those same metrics down by channel; see our guide to affiliate metrics if any of those terms aren’t second nature yet.
How sub IDs work: anatomy of a tracking link
A sub ID is just a parameter appended to your existing affiliate link. Take a typical base tracking
link, https://example.com/affiliate?ref=12345, and add a sub ID as a query parameter:
https://example.com/affiliate?ref=12345&subid=facebook_ad1
Here, facebook_ad1 tells the platform this click came from an ad you’re calling
“ad1” on Facebook. When someone clicks, the platform records the sub ID with the click; if
a sale follows, the same sub ID attaches to the conversion, so your reporting can filter by it.
Most platforms support more than one sub ID per link, so you can track multiple dimensions at once
— source and creative, for instance — with &subid1=facebook&subid2=ad1.
The exact parameter names vary by network (subid, s1–s5,
“custom parameters,” “tracking ID”), but the mechanism is the same everywhere: a
label attached to the click that survives through to the conversion report.
Common use cases for sub IDs
The specific label you choose depends entirely on what question you’re trying to answer. Some of the most common uses:
- Tracking traffic sources.
&subid=google_adsversus&subid=email_campaignshows whether a sale came from a paid search click or a newsletter send. - Testing ad creatives.
&subid=ad_image1versus&subid=ad_video2compares a static image against a video without guessing which pulled its weight. - Split-testing landing pages.
&subid=lp_version1versus&subid=lp_version2shows which page design actually converts better. - Keyword-level performance.
&subid=keyword_digital_marketingties a specific search keyword to its downstream sales, otherwise invisible once someone leaves the results page.
Implementing sub IDs in your campaigns
Getting sub IDs into your links correctly is mostly a matter of following a process, not writing code. Four steps cover almost every situation:
- Decide what you’re trying to learn. Add a sub ID because you have a specific question — which source, which creative, which page — not just because you can.
- Check how the platform expects them formatted. Look for a field labeled “Sub ID,” “Tracking ID,” or “Custom Parameters,” and follow its naming rules.
- Use a URL builder if one’s available. It beats hand-editing query strings and risking a typo.
- Test before you launch. Click your own tagged link and confirm the sub ID shows up correctly in your reporting — before you spend budget relying on it.
Tip: Name sub IDs so a stranger could understand them a year from now — google_display_ad1 tells you something useful, ad123 tells you nothing. Future-you is reading these reports too.
Analyzing sub ID data and best practices
Collecting sub IDs is only half the job — the value shows up when you actually use the data to change what you do. A simple loop works well:
- Pull the report filtered or grouped by sub ID, rather than looking at campaign totals.
- Compare the metrics that matter — click-through rate, conversion rate, revenue per sub ID — side by side.
- Look for repeatable patterns, not one-off spikes, in which sub IDs consistently outperform the rest.
- Act on it. Shift budget toward what’s working, retire what isn’t, and keep testing new variants against your current best.
A few habits make that loop easier to sustain:
- Keep sub IDs descriptive — a consistent naming pattern beats a clever shorthand once you have to look back at old data.
- Standardize the convention across every campaign, so
fb_ad1always means the same thing regardless of platform. - Don’t over-fragment. Tracking every conceivable variable turns reports into noise; track the two or three that actually drive decisions.
- Pair sub IDs with other tracking methods. They answer “which channel”; cookies and postbacks still connect the click to the sale.
- Never put personal data in a sub ID. Names, emails, or anything identifying a person don’t belong in a tracking parameter.
Compliance caution: sub IDs sit in URLs and get stored in logs for a long time, so keep them free of anything personally identifiable. The UK ICO’s guidance on cookies and similar technologies is a useful reference if you’re unsure what counts as identifying data.
Challenges, limitations, and where sub ID tracking is headed
Sub IDs are simple in concept but not free of friction. The limitations worth knowing before you build a whole reporting workflow around them:
- Manual setup at scale. Tagging links one at a time is fine for a handful of campaigns; it becomes a real time cost once you’re running dozens.
- Data overload. Too many sub IDs, tracked too finely, leaves you with more rows than insight — analysis paralysis instead of decisions.
- Cookie and browser restrictions. Where sub ID data still depends on a browser cookie rather than a server-side record, ad blockers and privacy settings can quietly break it.
- Cross-device gaps. A visitor who clicks on a phone and buys later on a laptop is hard to connect without extra tracking infrastructure.
Server-to-server (S2S) tracking addresses most of this by making sub ID reporting far less dependent on a cookie surviving in someone’s browser, and as privacy rules tighten, the industry is leaning toward tracking that relies less on cookies and more on server-side, non-identifying records — good for accuracy and compliance alike. Sub IDs aren’t going away; they get more useful as the rest of the tracking stack gets more reliable around them.
If you’re still choosing a tracking platform, our affiliate tracking software reviews weigh exactly this kind of sub ID and reporting support. And if you’re newer to affiliate marketing generally, start with the affiliate roadmap — sub IDs are far more useful once the fundamentals are already in place.
Frequently asked questions
What exactly is a sub ID in affiliate tracking?
A sub ID is a custom label added to your affiliate link as a query parameter, such as &subid=facebook_ad1. The platform stores that label with the click and carries it through to any sale, so you can see performance broken down by source, creative, or page instead of one blended total.
How many sub IDs can I use on one link?
It depends on the platform. Many support several simultaneous sub IDs (often labeled subid1 through subid5), letting you track more than one dimension — source and creative together, for example — on a single link.
Do sub IDs cost anything to use?
No. Sub IDs are a labeling feature built into the affiliate link itself, included with the tracking platform or network you’re already using. The effort is in naming and organizing them well, not in cost.
Can I put customer information in a sub ID?
No. Sub IDs should describe the traffic — source, creative, placement — never a specific person. They can sit in logs and reports for a long time, so names, emails, or other identifying details create a privacy risk you don’t need to take on.
Some links on ClickProfits are affiliate links — see our affiliate disclosure.