Thomas Osayi

November 22, 2026 · 9 min read · Thomas Osayi

How to build a creator affiliate tracking system: codes, links and ad attribution

How to track which creator drove each sale: discount codes, share links and ad-level attribution compared, the data model, payouts and real SQWAD figures.

A brand sends free product to forty creators, half of them post, a few videos go viral and sales jump. Then someone asks the obvious question at the end of the month: which creators actually made money for us? If the honest answer is a spreadsheet, a pile of DMs and a guess, the program is running blind.

I built SQWAD, UGC creator program software for Shopify brands, around exactly that question. Before that I built the creator portal for TheHoopGang. This guide covers how creator tracking actually works, the three main methods and where each one breaks, the data you need to store, and how to decide whether to build or buy.

What is a creator affiliate tracking system?

It is the part of a creator program that connects each order to the creator whose content caused it, then turns that connection into commission.

Every tracking system has the same four jobs, whatever tools sit underneath:

  • Give each creator something identifiable: a code, a link, a video ID or all three.
  • Capture that identifier when an order happens, or match it afterwards from ad data.
  • Record the order against the creator with the commission rate that applied at that moment.
  • Hold, adjust and pay the commission, including reversals for refunds.

The hard part is the second job. A buyer who sees a creator's video can buy in at least three ways: by typing a code at checkout, by tapping the creator's link, or by tapping an ad the brand built from the creator's video. Each path leaves a different trail, and a system that only watches one of them will undercount the others. That is why the method you choose matters more than the software you choose.

Codes are easiest to launch, links are best for organic audiences, and ad-level attribution is the only option that credits creators for paid ads.

Discount codes

Best for: small programs and creators whose audience buys on a podcast mention or a story.

Cost range: close to free. Shopify lets you create codes with a fixed amount off, a percentage off, buy X get Y or free shipping, and a script or app can read which code each order used.

Pros: works offline and across devices, buyers like a deal, and the order itself carries the code.

Cons: codes leak onto coupon sites, so creators get credit for sales they did not cause. Buyers forget codes, so creators lose credit for sales they did cause. And every sale is discounted, which eats margin.

Share links

Best for: creators with an engaged audience who click through from a bio or a story.

Cost range: low if your store or creator tool generates links, higher if you build your own redirect and cookie handling.

Pros: buyers pay full price, and SQWAD's creator share links credit store sales to creators wherever their audience finds them.

Cons: credit is lost when a buyer switches from phone to laptop, clears cookies or returns a week later through search.

Ad-level attribution

Best for: brands that turn creator videos into paid ads, which is most UGC programs that scale.

Cost range: the most expensive to build yourself, because it means a connection to the ad platform and matching logic.

Pros: credits creators for the sales their videos make as ads, which codes and links never see.

Cons: depends on the ad platform's reported results and on disciplined ad naming.

Why does ad-level attribution matter so much for UGC programs?

Because once a creator's video runs as an ad, the buyer never sees a code or a creator link, so the creator's best work becomes invisible to code and link tracking.

In a UGC program the brand usually licenses the video and runs it from its own ad account. The creator made the asset that sold, but the order arrives through the brand's ad with no creator identifier attached. A program that pays only on codes and links quietly underpays its best creators, and the brand loses the data it needs to decide who to keep.

SQWAD solves this at the ad level. Each approved video gets a short ID, and the brand adds that ID to the ad name when it launches the ad. SQWAD reads results from Meta and matches each ad back to its creator and video, then shows spend, revenue, orders and return on ad spend per creator and per video. Setup is signing in with Facebook and choosing an ad account, with no API keys to paste.

SQWAD's revenue attribution page: every Meta ad traced back to the creator and the video that made the sale.
SQWAD's revenue attribution page: every Meta ad traced back to the creator and the video that made the sale.

The naming convention is the unglamorous part that makes it work. If the media buyer forgets the ID, that ad is unattributed. Build a check that lists active ads without a recognised ID, and show it to whoever launches ads every week. At the time of writing SQWAD's attribution covers Meta (Facebook and Instagram) ads, not TikTok ads, which is worth knowing if your spend is split.

What data model does a creator tracking system need?

You need creators, trackable assets, attributed orders and commission entries as separate records, so every number on a dashboard can be traced back to an order.

A model I would start with:

  • creators: id, brand id, status, commission rate, payout details reference.
  • assets: id, creator id, type (code, link or video), the code string, the link slug or the short video ID.
  • attributed orders: order id, asset id, creator id, source (code, link or ad), order total, currency, attributed at.
  • commission entries: id, attributed order id, amount, rate used, status (pending, approved, reversed, paid), hold until date.
  • payouts: id, creator id, total, period, paid at, reference to the payment provider.

Two rules save pain later. First, copy the commission rate onto each entry instead of reading it from the creator record, so raising a creator's rate does not rewrite last month's money. Second, decide what happens when one order matches two sources, for example a buyer who clicked a creator's ad and then typed another creator's code. Pick a rule, such as last touch wins or code beats link, write it down and show it to creators. Arguments about credit are almost always arguments about an unwritten rule.

For multi-brand software like SQWAD, every one of these records also belongs to a brand, and that isolation has to be enforced in the database rules, not just hidden in the interface.

How should commission and payouts be calculated?

Calculate commission on what actually sold after discounts and refunds, hold it through the refund window, then pay it out in batches.

SQWAD calculates commission on what actually sold, which is the right default. A practical flow:

  • When an order is attributed, create a commission entry in pending with a hold until date set past your return window, for example 30 days.
  • When a refund or cancellation arrives from Shopify, mark the entry reversed instead of deleting it.
  • When the hold date passes, move the entry to approved.
  • Pay approved entries on a fixed schedule, weekly or monthly, and record the payout reference.

Show creators the same statuses you use internally. A creator who can see "pending until the 14th" does not send a message asking where their money is. The TheHoopGang portal taught me that most messages in a creator program are status questions, and a visible status answers them.

Disclosure matters too. The FTC's guidance says a paid relationship should be disclosed clearly and conspicuously near the recommendation, and a bare "affiliate link" label may not be enough. Put that expectation in the creator agreement. This is general information, not legal advice.

What results can good attribution show?

It shows revenue, ad performance and commission per creator, which is what lets a brand decide who to keep, who to pay more and which videos to scale.

SQWAD's published TheHoopGang case study reports $500K+ in revenue attributed to creator videos, a 3.7x return on ad spend across 759 creator ads, $41K+ in commission paid to creators and 62 creators, all in under 10 months.

SQWAD case study page for TheHoopGang: $500K+ revenue attributed to creator videos, 3.7x return on ad spend across 759 creator ads, $41K+ commission paid and 62 creators, as published on joinsqwad.com.
SQWAD case study page for TheHoopGang: $500K+ revenue attributed to creator videos, 3.7x return on ad spend across 759 creator ads, $41K+ commission paid and 62 creators, as published on joinsqwad.com.

The point of those numbers is not that every program will match them. It is that none of them could be reported at all without ad-level attribution. The 759 creator ads are exactly the sales that codes and links would have missed.

A worked example: a skincare brand with 25 creators

This is an illustration, not a client. A skincare brand on Shopify runs a program with 25 creators. Each gets a 15 percent code, a share link and 10 percent commission. The brand also runs the best eight videos as Meta ads.

After a month the code report shows $9,000 in sales, but a quick search finds two codes posted on coupon sites, accounting for $2,100 of it. The link report shows $4,500. The ads report, once each ad carries its creator's video ID, shows $31,000 in attributed revenue across the eight videos.

Without ad attribution, the brand would have paid commission on roughly $11,400 and believed the program was small. With it, the brand sees that three creators produced most of the ad revenue, offers them a retainer, retires the leaked codes and stops paying the creators whose content never sold. The fix was not more software features. It was capturing the third path to purchase.

What does it cost to build, and should you buy instead?

Most brands should buy creator software first, and build only when their rules or integrations do not fit standard tools.

I covered the full decision in "Build or buy: software for running a brand creator program". In short, applications, product seeding, content review, payouts and attribution are already built in existing tools, so a custom build only pays off when your rewards, approvals or integrations are unusual.

If you do build, realistic ranges based on my SaaS packages:

  • From $250 for a working first version of one workflow, for example code and link tracking with a commission report.
  • From $1,200 for a SaaS MVP with auth, a creator dashboard, a database and payments.
  • From $3,000 for a full platform with brand and creator roles, admin tools and integrations such as Shopify and Meta.

Payouts add their own work. If you plan to pay creators through the platform, read up on Stripe Connect payouts before you design the payout tables.

What mistakes break creator attribution?

The most common mistake is trusting one source of truth, usually codes, and assuming it captures everything.

Others I see often:

  • Launching ads without the creator's video ID in the ad name, so the best performing content is unattributed.
  • Reading the commission rate live from the creator profile, which silently changes history when a rate changes.
  • Paying commission on the order date, then chasing refunds from creators.
  • Leaving overlapping credit rules undefined, which turns every double match into a dispute.
  • Hiding statuses from creators, which floods the team with "did my sale count?" messages.

The bottom line

A creator affiliate tracking system has to watch every path a buyer takes: codes, links and, for UGC programs, the ads built from creator videos. Store attributed orders and commission entries separately, copy the rate onto each entry, hold commission through the refund window and show creators the same statuses you see. Start with existing creator software unless your program is genuinely unusual. If it is, send me the rules you need through the SaaS MVP service page and I will tell you what a first version would take.

Questions, answered in one line

What is the most accurate way to track creator sales?

No single method is complete, so the most accurate setups combine share links or codes for organic sales with ad-level attribution for creator videos that run as paid ads.

Are discount codes enough to track affiliates?

They work for a small program, but codes get shared on coupon sites and buyers often forget them, so they both over-credit and under-credit creators.

How do you attribute a Meta ad to a creator?

Give each approved creator video a short ID, put that ID in the ad name when the ad launches, then read ad results from Meta and match each ad back to its creator and video.

When should commission be paid out?

Pay commission after the store's refund window closes, because paying on the order date means clawing money back whenever an order is refunded.

Do creators need to disclose affiliate links?

Yes, the FTC expects a clear and conspicuous disclosure of the paid relationship near the recommendation, and this is general information, not legal advice.

How much does it cost to build a custom creator tracking system?

Thomas Osayi builds a working first version of one tracking workflow from $250 and a full multi-role creator platform with admin tools and integrations from $3,000.

Sources

About the author

Thomas Osayi is a full-stack developer in Los Angeles studying computer science at Loyola Marymount University. He founded and built SQWAD, a SaaS platform Shopify brands use to run creator programs, and builds custom Next.js websites, SaaS MVPs and fixes for AI-built apps for businesses and founders.

See his work · Services and prices

Related articles

SaaS MVP and full-stack web app development

I build SaaS MVPs and full-stack web apps in Next.js, TypeScript and Firebase or Postgres: auth, dashboards, payments, roles and admin tools. Founder of SQWAD.

See the service