Payments integration
Lemon Squeezy attribution for every order and renewal
Selling templates, courses, plugins, or a small SaaS through Lemon Squeezy? SourceLoop shows whether each order came from an X thread, a newsletter feature, a search ranking, or an ad, and keeps crediting that source as subscriptions renew.
Free 7-day trial. No credit card required.
- Connection
- Webhook + checkout[custom]
- Checkouts
- Buy URLs, Lemon.js, API
- Products
- One-off and subscriptions
- Your automations
- License keys, Discord keep working
How does SourceLoop work with Lemon Squeezy?
SourceLoop adds marketing attribution to Lemon Squeezy through a webhook and checkout custom data. The webhook delivers order, subscription, renewal, and refund events; SourceLoop's first-party tracker supplies two visitor identifiers that you append to hosted Buy URLs as checkout[custom] parameters, pass through the Lemon.js overlay, or include in API-created checkouts. Each order and every subscription_payment_success renewal joins the original visitor's channel, campaign, and journey, giving revenue, MRR, and LTV by source, with sales ready to report to Meta, Google Ads, Microsoft Ads, and ChatGPT Ads.
Updated November 2026
The gap
What Lemon Squeezy's dashboard can't tell you
-
Orders don't record the launch post
Lemon Squeezy shows the order, the product, and the buyer. Which tweet, newsletter mention, or directory listing sold it is missing.
-
Buy links shared everywhere lose context
The same Buy URL ends up in a thread, a YouTube description, and an email. Without tagging each copy, every sale looks the same.
-
Subscription revenue drifts from its source
The first order might be attributed, but renewals months later aren't, so channels that bring long-term subscribers look no better than one-time buyers.
What you get
What your Lemon Squeezy store gains
-
Each sale with its true origin
Orders carry the visitor's acquisition channel, campaign, landing page, and the pages they browsed before checkout opened.
-
Renewals credited to the first sale
subscription_payment_success events join the subscriber's record, so recurring revenue keeps building on the channel behind the first order.
-
Refunds come off the right channel
A refunded payment is subtracted from the channel that made the sale, even weeks later.
-
Works with the overlay and the API
Plain Buy links, the Lemon.js overlay, and server-created checkouts all carry the same custom data keys.
-
Compare launch channels on revenue
See revenue, MRR, and ROAS for X, newsletters, communities, search, and ads side by side, credited by first-touch or multi-touch attribution models.
The data
What each Lemon Squeezy customer arrives with
SourceLoop pairs Lemon Squeezy's order data with the visitor history recorded before checkout.
| Field | Example | Written to |
|---|---|---|
| Channel at purchase | Organic Social · x.com | Contact |
| UTMs of the converting visit | utm_source=newsletter, utm_campaign=launch-week | Contact |
| First landing page and referrer | /templates/notion-crm · x.com | Contact |
| Visits and time before buying | 2 visits · 5 min | Journey |
| Order and renewal history | Orders, renewals, refunds | Contact |
| Buyer name and email | From Lemon Squeezy | Contact |
Compared
Lemon Squeezy alone vs tagged Buy links vs SourceLoop
Tagged Buy links means appending your own UTM values to every copy of a Buy URL, one per placement, and reading them back from order data.
| Capability | Lemon Squeezy alone | Tagged Buy links | SourceLoop |
|---|---|---|---|
| Channel on each order | No | Partly Only tagged copies | Yes From the visit |
| Renewals credited to that channel | No | No | Yes Every renewal |
| Pages read before buying | No | No | Yes Full path |
| Refunds netted per channel | Partly Store totals | No | Yes Against the lead |
| Order value reported to ads | No | No | Yes Server-side |
Why it holds up
Know what's selling, not just that it sold
SourceLoop records the visitor on your own site before the Lemon Squeezy checkout opens and keeps every later order and renewal linked on its servers, without touching your store's other automations.
Buyer journeys stored first-party on your site
Sales reported to ad platforms from the server
The posts and pages behind each order
Store revenue by launch channel
How it works
Connect Lemon Squeezy in four steps
Snippets for Buy URLs, Lemon.js, and the API are in How to track lead source in Lemon Squeezy.
-
<script async src="https://t.sourceloop.ai/tracking-v3.js"></script>
01Add SourceLoop to your site
Install the script on product and pricing pages so the visit is recorded before checkout.
-
Webhook
- Callback SourceLoop
- Events Orders, subscriptions
02Create the webhook
In your Lemon Squeezy store settings, add a webhook pointing at SourceLoop's URL with the events listed in the drawer.
-
Signing secret
- Secret ••••••••
- Status Checked
03Verify with the signing secret
Copy the webhook's signing secret into SourceLoop, which uses it to confirm each event is genuine.
-
- Channel X / Social
- Campaign launch-week
- Renewals n/a
04Append custom data to checkouts
Add the tracker's identifiers as checkout[custom] parameters on Buy URLs, or in your API checkout request.
Conversion sync
Send Lemon Squeezy sales to your ad accounts
Report each order, each new subscriber, or every recurring charge with its value to Google Ads, ChatGPT Ads, Meta, and Microsoft Ads as offline conversions, so launch campaigns optimise toward revenue.
- Each order
- Becomes paying, valued in months
- Every successful payment, renewals included
Used by 750+ marketing teams, agencies, and SaaS companies
FAQ
Lemon Squeezy tracking questions
Does it work with hosted Buy URLs and API-created checkouts?
Yes. The webhook setup is the same for both. Only the way you attach custom data differs: query parameters on Buy URLs, or fields in your API request.
Lemon Squeezy is the merchant of record. Does that affect reporting?
No. VAT, sales tax, and payouts are handled by Lemon Squeezy. SourceLoop records orders, subscriptions, and renewals at the gross amount the customer paid.
Are subscription renewals attributed to the original source?
Yes. Renewal payments land on the subscriber's existing contact, so their lifetime value accrues to whichever channel produced the first order.
How are refunds handled?
subscription_payment_refunded events reduce the revenue of the lead they came from, and channel totals in the Traffic and Revenue report reflect that.
I open checkout with the Lemon.js overlay. Is that different?
No. Add the custom-data query parameters to the URL before calling LemonSqueezy.Url.Open, exactly as you would for a plain link.
Will license keys, Discord roles, and receipts still work?
Yes. SourceLoop uses its own webhook endpoint, so every other destination you've set up keeps receiving events.
Is the tracking privacy-friendly?
Yes. The tracker is first-party on your domain, honours Google Consent Mode, and offers a cookieless mode.