Meta Conversions API for affiliates: send sales Meta can actually match
November 28, 2026 · Hoplytic team · 6 min read
Read the video transcript
Meta's pixel can't load on a merchant's checkout. So how does Meta hear about an affiliate sale?
Store the fbclid and the click time when the visitor lands. Wait for the network to report the sale with your click ID. Then send a Purchase event to your pixel's events endpoint.
The fbc value starts with fb, then one, when you build it on a server. Next is the click time in milliseconds. A common bug is sending seconds. Then the fbclid, exactly as it arrived.
Event time is when the sale happened, in seconds, and under seven days old. Event ID is the network's order ID, so a resent sale isn't counted twice. And value is your commission, with a currency code.
Send one sale per request, and prefer a postback or hourly API sync over a weekly CSV.
Under Send back, add Meta with your pixel ID and access token. Each sale is sent as one server event, within about twenty seconds of the network reporting it.
The full guide is right below. Hoplytic: ad tracking made simple.
Key points
- An affiliate sale reaches Meta only as a server event, because the pixel never loads on the merchant's checkout.
- The fbc value, built as fb.1.<click time in milliseconds>.<fbclid>, is what ties the sale to the ad click.
- Meta rejects the whole request if any event_time is more than 7 days old, so slow networks and late report uploads lose sales.
- Use the network's order or transaction ID as event_id so a resent or updated sale is not counted twice.
- Send a few events with a test event code first and read Meta's answer before you switch your campaign to optimize for the event.
You can't put Meta's pixel on a merchant's thank-you page, so for affiliate offers the Conversions API is the only way Meta hears about a sale. Getting the event accepted is easy. Getting it matched to the right ad click is where most setups fail.
Short answer: store the fbclid and the click time when the visitor lands, wait for the network to report the sale with your click ID, then POST a Purchase event to the pixel's /events endpoint with fbc built from that fbclid, an event_time under 7 days old, the order ID as event_id, and your commission as value.
This guide is about the event itself. For the overall chain from ad to sale, see Facebook ads affiliate tracking.
What you need before you start
- A pixel (dataset) ID from Events Manager. The pixel code does not need to be installed anywhere for server events.
- An access token: in Events Manager, open the dataset, go to Settings, and generate a token under Conversions API. Treat it like a password.
- The fbclid of every Meta click, saved by your tracker at the moment of the click, with the time.
- A sale report that carries your click ID back from the network, by postback, API or report upload. Without it you can't find the fbclid again. See how to track affiliate sales.
The event, field by field
A minimal affiliate event looks like this:
POST https://graph.facebook.com/<version>/<PIXEL_ID>/events?access_token=<TOKEN>
{
"data": [{
"event_name": "Purchase",
"event_time": 1795867925,
"action_source": "website",
"event_source_url": "https://yoursite.com/best-vpn",
"event_id": "ORD-88412",
"user_data": {
"fbc": "fb.1.1795854102000.IwAR2F4dbP0l7Mn1",
"client_user_agent": "Mozilla/5.0 (iPhone; CPU iPhone OS 18_1 like Mac OS X) ..."
},
"custom_data": { "value": 32.00, "currency": "USD" }
}]
}
| Field | What to put in it |
|---|---|
event_name | Purchase for a sale, Lead for a CPL offer. It has to match the event your campaign optimizes for. |
event_time | Unix time in seconds when the sale happened (the network's conversion time), not when you send it. |
action_source | website when the buyer acted on a website. Meta also accepts values such as other and system_generated. |
event_source_url | Meta's docs say this is required for website events. Use your landing page URL. |
event_id | The network's transaction or order ID. It lets Meta drop duplicates. |
user_data.fbc | The click identifier, built from the fbclid (below). |
user_data.client_user_agent | The browser user agent from the click. Meta expects it on website events. |
custom_data.value, currency | Your commission (or order value) and a three-letter currency code. |
Building fbc from the fbclid
Meta's format is fb.<subdomainIndex>.<creationTime>.<fbclid>:
- fb is always the same.
- subdomainIndex is
1when you build the value on a server and never set the_fbccookie. - creationTime is when you first saw the fbclid, in milliseconds. Use the click time your tracker stored. A common bug is sending seconds here.
- fbclid goes in exactly as it arrived. It is case sensitive: no lower-casing, trimming or URL decoding twice.
Example: a click at 2026-11-28 08:21:42 UTC with fbclid=IwAR2F4dbP0l7Mn1 gives fb.1.1795854102000.IwAR2F4dbP0l7Mn1.
Why match quality looks low, and why that's fine
Events Manager scores each event's customer information. A store sends hashed emails, phone numbers and IP addresses. As an affiliate you never see the buyer's email, so your events usually carry only fbc and the user agent. The score will look weak next to a store's. What matters for you is that fbc is present on every event: it points at the exact ad click, which is the strongest link you can give. Don't invent or guess personal data to raise the score.
The 7-day wall
Meta accepts an event_time up to 7 days in the past. If one event in a request is older, Meta returns an error for the whole request and processes none of the events in it. That has three practical effects:
- Send one sale per request, or filter old ones out first, so one late sale doesn't sink the rest.
- Late reports lose sales. If your network only shows conversions in a weekly CSV, many will be too old by the time you upload them. Prefer a postback or an hourly API sync. See network API vs postback.
- "Approved only" can be too slow. Some networks approve after 14 or 30 days. If you wait for approval, Meta never gets those sales.
Deduplication with event_id
Meta drops an event when it has already received one with the same event_id and event_name within 48 hours, and keeps the first. Use the network's order ID: when the network sends a pending sale and later an approval for the same order, your second send is harmless. Without event_id, every retry after a timeout becomes an extra purchase in Ads Manager. Retries more than 48 hours apart are not protected, so don't resend old sales by hand.
Commission or order value?
Send your commission when you bid on ROAS: a $32 commission on a $400 order is $32 to you, and Meta should optimize for what you earn. Send the order value only if every network you run reports it, and keep it consistent. A mix makes ROAS targets meaningless. More in affiliate ROAS tracking.
Test before you trust it
- In Events Manager, open Test events and copy the test code (it looks like
TEST48213). - Send an event with
"test_event_code": "TEST48213"at the top level of the request, next todata. - Read the response. Success returns
events_received: 1. An error explains the problem, for example an oldevent_timeor an invalid token. - Check the event shows up in Test events with
fbclisted under customer information. - Remove the test code, then make a real test sale through your own ad if the network allows it.
Errors you will meet
- Invalid OAuth access token: the token was revoked or belongs to another dataset. Generate a new one.
- event_time too far in the past: the 7-day limit. Check that you send seconds, not milliseconds, and that the time zone is right.
- Events received but no purchases in Ads Manager: the sale came from a click without fbclid (organic post, a link shortener that dropped the query string), or fell outside your ad set's attribution setting. Check how many sales actually carried an fbclid.
- Twice as many purchases as sales: missing
event_id, or the same sale sent from two tools.
Doing it in Hoplytic
The link maker stores the fbclid, click time and user agent with each Meta click. Under Send back, add Meta with your pixel ID and access token. Each sale is sent as one server event with fbc built as above, your tracking link as event_source_url and the network's transaction ID as event_id, within about 20 seconds of the network reporting it. You can set the event name (default Purchase) and a test event code while testing, and choose pending or approved sales and commission or order value. Sales older than 7 days are not sent. Setup steps are in the help article.
Questions people ask
Can I use the Meta Conversions API without a website pixel?
Yes. You need a pixel (dataset) ID and an access token from Events Manager, but the pixel code does not have to be on any page. Affiliates often send server events only, because the sale happens on the merchant's site.
How old can a Conversions API event be?
Meta accepts events with an event_time up to 7 days in the past. If one event in a request is older, Meta returns an error for the whole request and processes none of its events.
What is the fbc parameter?
fbc is Meta's click identifier in cookie format: fb, a subdomain index, the time the click was first seen in milliseconds, and the fbclid exactly as it arrived. A server that never set the _fbc cookie uses 1 as the subdomain index.
Should I send pending affiliate sales to Meta?
Send pending sales if your network approves most of them and you want Meta to learn fast. Send approved sales only if rejections are common, but watch the 7-day limit: a sale approved after a week can no longer be sent.
More in Conversion tracking
Also: tracking glossary · ad platform macros · Markdown copy