Skip to content New SourceLoop MCP: chat with your attribution data in Claude, ChatGPT & Cursor
SourceLoop

How to Track Stripe Payments as Meta Ads Conversions

Meta optimizes for the events it can see, usually signups. Here is how to send Stripe payments to Meta through the Conversions API and decide if renewals count.

Stripe payment sent back to Meta Ads as a conversion
Table of contents
  1. Why Meta can't see your Stripe payments
  2. What you need before you start
  3. How to track a Stripe payment as a Meta Ads conversion
  4. Step 1: Install the SourceLoop tracking script
  5. Step 2: Connect Stripe with a webhook
  6. Step 3: Pass SourceLoop IDs into your checkout
  7. Step 4: Connect Meta Ads to SourceLoop
  8. Step 5: Get your Pixel ID and a System User token
  9. Step 6: Map the Stripe payment to a Meta event
  10. Step 7: Choose what counts as a conversion
  11. Step 8: Test with a test event code
  12. What to do once events are flowing

Meta optimizes your campaign for whatever event it can see. For most SaaS accounts that's a signup or a lead, not a payment.

The fix is to send the Stripe payment to Meta yourself, tied to the ad click. This guide covers the setup, plus a question most guides skip: should renewals go to Meta too?

Why Meta can't see your Stripe payments

The Meta Pixel runs in the visitor's browser. Stripe moves the payment out of it, in three ways:

  • Checkout happens on a Stripe-hosted page, so the visitor leaves your site before they pay.
  • Safari, iOS privacy settings and ad blockers already drop a good share of Pixel events.
  • Renewals have no page view at all. Stripe bills the card and nobody opens a browser.

So the payment has to travel server to server. Stripe sends a webhook, SourceLoop adds the Meta click data it saved earlier, and the Conversions API (CAPI) delivers the event to Meta.

An ad click carries an fbclid to your site, then to Stripe Checkout. A Stripe webhook reaches SourceLoop, which sends the conversion to Meta through the Conversions API.The click data stays attached the whole wayAd clickVisitor lands withan fbclid in the URLYour siteSourceLoop saves theclick and browser IDsStripe CheckoutCustomer pays, IDsride in metadataStripe webhookPayment event goesto SourceLoopMetaEvent arrives withvalue and click data
From ad click to Meta conversion: the click data travels with the visitor, then Stripe's webhook brings the payment back.
The payment gives Meta the value. The click data tells Meta which ad deserves the credit.

What you need before you start

  • A Meta ad account, and a Pixel (or Dataset) in Events Manager.
  • Admin access to your Meta Business, so you can create a System User token.
  • A SourceLoop workspace with the tracking script installed, and the Admin or Owner role.
  • Developer or owner access to your Stripe Dashboard, to add a webhook endpoint.

How to track a Stripe payment as a Meta Ads conversion

Eight steps. The first three get Stripe data into SourceLoop with the Meta click data attached. The rest connect Meta and decide what gets sent.

Step 1: Install the SourceLoop tracking script

In SourceLoop, open Setup, then Tracking code, and copy the snippet. Paste it into the head of every page, starting with the ones that lead into checkout. It saves the fbclid from the ad click and the Meta browser cookies, so they're there when the payment arrives.

SourceLoop Setup page showing the tracking code snippet to copy
The tracking code lives under Setup in SourceLoop.

Want to confirm it's firing? Run through the verify tracking guide. If fbclid is new to you, click IDs explained shows where it comes from.

Step 2: Connect Stripe with a webhook

Go to Setup, then Payment, and click the Stripe card. The drawer that opens shows your webhook URL.

SourceLoop Setup Payment page with cards for Stripe and other payment providers
Start from the Stripe card on the Payment page.

Copy the URL. In Stripe, open Developers, then Webhooks, click Add endpoint and paste it in. Select these events:

  • charge.succeeded
  • charge.refunded
  • customer.subscription.created
  • customer.subscription.updated
  • customer.subscription.deleted
  • invoice.paid

Save the endpoint, reveal its signing secret (it starts with whsec_) and paste it into the SourceLoop drawer. The status shows pending until Stripe sends its first verified event, then it turns active.

SourceLoop Stripe drawer with the webhook URL and signing secret fields
Webhook URL on one side, signing secret on the other.

Already sending Stripe events to Zapier or your own app? Keep those endpoints. Stripe delivers each event to every endpoint on its own. Stripe's webhook documentation has the details.

Step 3: Pass SourceLoop IDs into your checkout

The webhook tells SourceLoop a payment happened. It doesn't say who paid. So hand Stripe the visitor's IDs when you create the checkout. The tracker gives you a helper for that:

const meta = window.sourceloop.checkoutMetadata();
// { sourceloop_anonymous_id: '...', sourceloop_id: '...' }

Send that object to your server with the price ID, then set it as metadata on the Checkout Session. For subscriptions, set it on subscription_data too:

const session = await stripe.checkout.sessions.create({
  mode: 'subscription',
  line_items: [{ price: priceId, quantity: 1 }],
  success_url: 'https://your.site/thanks',
  cancel_url: 'https://your.site/pricing',
  metadata: meta,
  subscription_data: { metadata: meta },
});

Add the subscription_data part even if you only plan to send first payments. Stripe copies it onto each invoice, so you can add renewals later without touching code. Stripe's metadata guide explains how the copying works.

On Payment Links or Payment Intents? The Stripe lead source guide has a snippet for each.

Step 4: Connect Meta Ads to SourceLoop

Open Setup, then Ad Platforms, and connect your Meta ad account from the Meta Ads card. Once it's connected, the card shows the ad account name. The connect Meta Ads guide covers the permissions.

Step 5: Get your Pixel ID and a System User token

SourceLoop needs two things from Meta: the Pixel ID and a token that lets it write events.

  1. Open Events Manager in Meta Business Suite and pick the Pixel (or Dataset) tied to your ad account.
  2. Copy the Pixel ID, the 15 to 16 digit number at the top of the Overview tab.
  3. Open Business Settings, then Users, then System Users, and add one named something like SourceLoop CAPI.
  4. Assign it your ad account and your Pixel, both with Manage permission.
  5. Click Generate New Token, tick ads_management and set the expiry to Never if it's offered.
  6. Copy the token right away. Meta only shows it once.
Meta Events Manager showing the Pixel overview where the Pixel ID is found
The Pixel ID sits at the top of the Overview tab in Events Manager.

Why a System User? A personal token expires after 60 days, and your sync quietly stops when it does. A System User token doesn't expire.

Step 6: Map the Stripe payment to a Meta event

Go to Setup, then Ad Platforms, then Meta Ads. Paste the Pixel ID and token into the CAPI configuration and save. SourceLoop checks the token, and the status turns Active if it's valid.

Then scroll to Conversion sync and click Add conversion mapping. The fields below are the ones that matter for Stripe. The Meta Conversions API help article lists the rest.

FieldWhat to pick for Stripe
Trigger event typeRealized revenue updated. It fires when Stripe confirms the money.
Trigger event name filterBlank matches every Stripe payment event. Enter one event name to narrow it (Step 7).
Attribution modelLast touch or first touch.
Meta event nameSubscribe, Purchase, or a custom name.
Include valueOn, with the value source set to sales_value, the amount Stripe collected.
Dedup window1440 minutes by default. Meta's own window is 7 days, and SourceLoop uses whichever is shorter.

Subscribe or Purchase?

  • Subscribe fits a new recurring plan.
  • Purchase fits one-off sales, and it's the safer pick if your campaigns already optimize for Purchase. You won't have to rebuild anything.

What SourceLoop sends with each payment

  • The event name, time and the landing page URL.
  • The Meta click cookie (fbc) and browser cookie (fbp), when they exist.
  • Hashed email, phone and name, plus the visitor's IP address and user agent.
  • Value and currency, and a stable event_id.

More signals mean better matching. Meta can match on the click cookie alone, but email and phone give it a second way to find the person.

Step 7: Choose what counts as a conversion

Should Meta hear about a customer once, or every time they pay? The trigger event name filter decides, and you can add more than one mapping.

SetupWhat Meta receivesGood for
First payment onlyOne event per new customerMost subscription businesses
Every paymentFirst payment and every renewalShort billing cycles, or when you want all revenue in Events Manager
Two mappingsFirst payment as Subscribe or Purchase, renewals under a custom nameOptimizing on new customers while still seeing renewal revenue

Renewals work differently on Meta than they do on Google, and the reason is time.

A timeline from the ad click to day 60. The first payment on day 2 falls inside the 7 day click window. Renewals on day 30 and day 58 fall outside it.7 day click windowPast the window: sent to Meta, ad rarely creditedDay 0Day 7Day 30Day 60Days since the ad clickAd clickFirst paymentRenewal 1Renewal 2
Meta credits an ad only for payments inside its attribution window, 7 days after the click by default.
  • Meta's default click attribution window is 7 days.
  • A renewal 30 days later still reaches Meta, but the ad usually gets no credit for it.
  • Meta also rejects events with a timestamp older than 7 days, so there's no sending them late. The Conversions API docs spell that out.

We'd start with the first payment only. If you want renewal revenue visible in Events Manager, add a second mapping that sends renewals under a custom name like SubscriptionRenewal, and keep your campaigns optimizing on the first payment.

Watch for double counting

If your thank-you page also fires a browser Pixel Purchase, Meta can count the same payment twice. It merges a browser event and a server event only when the event name and event_id both match. Meta's server event reference covers the rule. Two ways out:

  • Remove the browser Purchase event for this checkout and let CAPI handle it.
  • Or pass the same event_id from your Pixel call.

Step 8: Test with a test event code

  1. In Events Manager, open the Test events tab and copy the test code.
  2. Paste it into the CAPI configuration in SourceLoop and save.
  3. Open your checkout in an incognito window, add ?utm_source=test&utm_medium=verify&utm_campaign=stripe-check to the URL and pay. Stripe test mode works too.
  4. Watch the Test events tab. The event should show up within seconds. Check the name, value, currency and Match Quality.
  5. Remove the test code from SourceLoop so events go to production.
SourceLoop Contacts Hub showing a Stripe customer with revenue history and the visitor journey before purchase
The same customer in Contacts Hub, with revenue and the journey behind it.

Check Contacts Hub too. The test customer should be there with a revenue event attached. A test payment proves the plumbing works. Real credit shows up when someone who clicked a Meta ad pays.

What to do once events are flowing

Point a sales campaign at the event you mapped, Subscribe or Purchase. Then give it time. Meta's learning phase wants roughly 50 optimization events per ad set in a week, so a low volume account may need a few weeks before the numbers settle.

SourceLoop attribution dashboard with a Stripe revenue column next to source, medium and campaign
Stripe revenue next to each source and campaign in the attribution dashboard.

Use that dashboard as your cross-check. Ads Manager will report fewer paying customers than Stripe, because Meta only counts people it can tie to an ad. The gap is normal.

It comes from the same payment tracking data, and server-side conversion tracking covers how the push to ad platforms works.

Frequently asked questions

  1. Do I still need the Meta Pixel if I send Stripe payments through CAPI?

    Keep it for page views and other browsing events. For the payment itself, either let CAPI be the only source or make sure the Pixel and CAPI share the same event_id, so Meta counts it once.

  2. Should I map Stripe payments to Subscribe or Purchase?

    Use Subscribe for a new recurring plan and Purchase for one-off sales. If your campaigns already optimize for Purchase, mapping subscriptions to Purchase saves you from rebuilding them.

  3. Will Meta credit my ads for subscription renewals?

    Rarely. Renewals reach Meta if you send them, but Meta's default click window is 7 days, and most renewals land well after that. That's why most teams send the first payment only.

  4. What if the customer never clicked a Meta ad?

    SourceLoop sends the signals it has for that payment. Meta can only credit an ad when it can match the person to an ad interaction, so customers from search, email or direct traffic won't show up as Meta results.

  5. Why use a System User token instead of my own?

    Personal tokens expire after 60 days and tie the sync to one person's account. A System User token doesn't expire and belongs to the business.

  6. How long until a payment shows up in Events Manager?

    SourceLoop sends matching conversions on a 2 minute cycle, so allow a few minutes. With a test event code, it appears in the Test events tab within seconds.

  7. Does this work with Stripe Payment Links?

    Yes, with less detail. A Payment Link can only carry a client_reference_id, so SourceLoop falls back to matching on the customer's email when the full IDs are missing. Checkout Sessions give better results.

  8. Can I send the same Stripe payment to Meta and Google Ads?

    Yes. Add a mapping in each ad platform's drawer. The Google side is covered in our guide to tracking Stripe payments as Google Ads conversions.

Share this post

Post on X Share on LinkedIn

Keep reading

All posts

Track every conversion to its true source

Capture and send full attribution data from every signup, lead, booking, and sale to your CRM and ad platforms, so you know exactly what's driving revenue.

Without SourceLoop

Untagged

Kayden Floyd

kayden@abc.com

  • SourceUnknown
  • MediumUnknown
  • CampaignUnknown
  • Landing pageUnknown
Journey
No touchpoints captured

With SourceLoop

Auto-tagged

Kayden Floyd

kayden@abc.com · Acme Co.

  • Channel Paid Social
  • CampaignFree_demo
  • Landing page/pricing
Journey
Synced to HubSpot Google Ads Meta