Setup guides

How to add an affiliate program to your Framer site

Create a program on Anderro, add the tracking snippet in Framer's Custom Code settings, sell through Stripe Payment Links, and add a short script that puts the visitor ID on those links. No server needed.

Framer steps last checked December 4, 2026.

Start your program Pricing

Framer at a glance

SnippetProject Settings › Custom Code, start of <head>
Secret keyNot needed
PaymentsStripe Payment Links, or Paddle
Plan neededNot stated by Framer for custom code; a custom domain needs a paid plan

Set up in 4 steps

1. Create your program on Anderro

Sign up, add your product and choose what affiliates earn. Anderro then shows your tracking snippet with your public key filled in.

2. Add the snippet in Custom Code

In Framer, open Project Settings, then the Custom Code tab, and add a script. Paste the snippet, set it to run on all pages, and change the placement to the start of <head> (Framer's default is the end of <body>).

By default the snippet waits for the visitor's consent before it sets its cookie. Call window.anderro.optIn() when they accept cookies. Your setup screen in Anderro tells you if your program is set to track without waiting.

<script src="https://track.anderro.com/a.js" data-key="YOUR_PUBLIC_KEY"></script>

3. Connect Stripe and tag your Payment Links

In Anderro, open your product, choose Integrations, then Stripe, and copy your webhook URL. In Stripe, open Developers, then Webhooks, add an endpoint with that URL, select the seven events Anderro lists, and paste the endpoint's signing secret back into Anderro. Anderro keeps no access to your Stripe account.

Point your buy buttons at Stripe Payment Links, then add the script below next to the snippet (also in Custom Code, at the end of <body>). When a buyer clicks, it adds their visitor ID to the link as client_reference_id, and Stripe hands it back with the sale.

If your Payment Links use your own domain instead of buy.stripe.com, change the address in the script to match.

<script>
  // Adds the Anderro visitor ID to Stripe Payment Links when they are clicked.
  document.addEventListener("click", function (e) {
    var a = e.target.closest && e.target.closest('a[href^="https://buy.stripe.com/"]');
    var vid = window.anderro && window.anderro.getVisitorId && window.anderro.getVisitorId();
    if (!a || !vid) return;
    var url = new URL(a.href);
    url.searchParams.set("client_reference_id", vid);
    a.href = url.toString();
  }, true);
</script>

4. Publish and test

Publish your site. Custom code does not run in Framer's canvas preview, only on the published site.

Then open your site through your own test referral link from Anderro, sign up and buy. The click, the sign-up and the sale show on your Anderro dashboard. Stripe's test mode works too: test payments never earn a commission.

How a sale is tied to an affiliate

The snippet remembers which affiliate sent a visitor and gives that visitor an ID. Your checkout passes the ID to Stripe, Stripe sends the sale to Anderro, and the affiliate who sent the customer is credited. Renewals need no extra code: they are matched to the customer from their first payment.

A customer who already bought through one affiliate stays with that affiliate, and an affiliate buying through their own link earns nothing unless you allow it.

What to know on Framer

  • If people sign up in an app on a subdomain (for example app.yoursite.com), add the snippet there too with the same key. The visitor's cookie is set for your whole domain, so the affiliate who sent them keeps the credit.
  • Framer has no server code or secrets, so you do not need your Anderro secret key on a Framer site.
  • US dollars only. A payment in another currency is not recorded, and Anderro's Integrations page tells you when one arrives.
  • Commissions wait out a hold you choose (7 to 90 days), so a refund inside the hold never costs you a commission.

If something does not show up

Nothing happens in the canvas

Custom code runs only on the published site, never in Framer's canvas preview.

The snippet loads late

Framer adds new scripts at the end of <body> by default. Move the snippet to the start of <head>.

My test click does not show up

The snippet waits for consent: accept cookies on your site, and check that your cookie banner calls window.anderro.optIn(). If your site sets a Content Security Policy, allow https://track.anderro.com in script-src and connect-src.

A sale shows up, but no affiliate is credited

The visitor ID did not reach the checkout. Open the payment in your billing dashboard and check it carries the ID, and buy in the same browser you opened the referral link in.

Questions

Does Framer have its own affiliate program?

Yes. Framer's Creator Program gives approved creators, Community publishers and Framer Experts affiliate links, tracked and paid through Dub. That pays you for promoting Framer. This guide is the other way round: running an affiliate program for an app you built. Looking for more software to promote? Browse SaaS affiliate programs on Anderro.

Can I sell through something other than Stripe on Framer?

Anderro reads sales from Stripe and Paddle. If you sell with Paddle's checkout buttons, follow the Paddle guide instead of the Payment Link step.

Does Anderro pay my affiliates?

No. Anderro tracks clicks, sign-ups and sales and works out what each affiliate earned. You pay affiliates yourself and mark the payout paid in Anderro.

Do my affiliates need an account on this platform?

No. They join your program on Anderro and get their link there. Their link is your site's address ending in ?ref= and their code.

Sources

Framer's menus and plans change; these are the pages we checked.

  1. Framer help: How to add custom code, checked December 4, 2026
  2. Framer Academy: Custom code, checked December 4, 2026
  3. Framer help: Accept payments, checked December 4, 2026
  4. Stripe docs: Payment Links URL parameters, checked December 4, 2026
  5. Framer help: How affiliate links work, checked December 4, 2026

Framer and Stripe are trademarks of their owners. Anderro is not affiliated with or endorsed by them.

Other setup guides

All setup guides · How tracking works