RovelaRovela
Back to the blog

By El Ghali Bennis · Published

Meta Pixel Conversions API: Setup, Deduplication, Fixes

Set up the Meta Pixel and Conversions API together, deduplicate events, fix missing purchases and give Facebook ads better data to cut CPA.

Meta Pixel Conversions API: Setup, Deduplication, Fixes

The Meta Pixel and the Conversions API (CAPI) do the same job through different routes. The pixel fires from your customer's browser; the Conversions API sends the same events from your server straight to Meta. Run both together, deduplicate them, and Meta sees more of your real sales, which improves optimization and lowers CPA.

Online store owner checking Meta Events Manager on a laptop at a kitchen table with packed orders beside her

If your Ads Manager shows 40 purchases and your Stripe dashboard shows 62, you aren't imagining it. A gap like that is common, and a 20–40% shortfall is a typical range store owners report when they compare the two. Browsers block scripts, people decline cookies, and iOS limits what apps can share. This guide walks you through how both tools work, how to set up the Conversions API, how to fix duplicates, and what to do when purchases don't show up.

What is the Meta Pixel Conversions API?

The Meta Conversions API is a way to send web events (page views, add to carts, purchases) from your server to Meta, instead of relying only on a browser script. It's designed to work alongside the pixel, filling gaps caused by ad blockers, browser privacy rules and lost cookies.

Think of it as a second witness. The pixel sees what happens in the browser. Your server sees what actually happened: the order was paid, the amount was $84.50, the customer's email was this one. When both report the same purchase, Meta keeps one copy. When only the server reports it, you still get credit for the sale.

Why the pixel alone loses data

Apple's iOS 14.5 update introduced App Tracking Transparency, which requires apps to ask permission before tracking. Industry surveys after launch put opt-in rates at roughly one in four users, which means most iPhone users became invisible to app-based tracking. Safari's Intelligent Tracking Prevention also caps cookies set by scripts at seven days (and just 24 hours in some link-decoration cases), and many browsers and extensions block the pixel's requests outright. You can read Meta's own explanation in the Conversions API documentation.

The result is under-reporting. Meta's algorithm optimizes on the conversions it sees. Fewer visible conversions means weaker learning, higher costs and campaigns that look worse than they are. That's why server-side tracking for Facebook ads is the standard iOS 14 Facebook tracking fix, even though it won't restore everything.

Meta Pixel vs Conversions API: what's the difference?

The pixel is client-side and easy to install; the Conversions API is server-side and more reliable. The pixel captures browsing behavior and cookies. CAPI captures confirmed backend events and customer data you already hold. Meta recommends using both, not choosing one.

Two marketers comparing browser and server event reports on a wide monitor in a bright open-plan office
FactorMeta PixelConversions API
Where it runsCustomer's browserYour server or platform backend
Blocked by ad blockersOftenNo
Depends on cookiesYesLess so (uses hashed customer data)
Setup difficultyLowMedium (low with a native integration)
Best atBrowsing signals, retargeting audiencesConfirmed purchases and leads
Recommended useBoth together, with deduplication

Do you still need the pixel?

Yes. The pixel gives you real-time browser signals such as the fbp and fbc identifiers, which help Meta match events to ad clicks. CAPI alone can work, but you'll typically lose match quality. The combination is what moves the needle.

Facebook Conversions API setup: three routes

You can set up the Facebook Conversions API through a platform integration, a partner tool or a direct server build. Pick the lowest-effort route that fits your stack; all three end in the same place, with browser and server events reaching Meta with matching IDs.

Option 1: native platform integration

Shopify, WooCommerce and others offer built-in Meta connections that turn on CAPI with a few clicks. It's the fastest route, but you're limited to the events the integration supports, and on Shopify it sits alongside paid apps and other tools in your stack. Rovela stores include the Meta integration by default, so the pixel and server events are part of the store rather than another plugin to maintain.

Here is the typical walkthrough in Events Manager for a partner integration:

  1. Open Events Manager. In Meta Business Suite, go to Events Manager and select your pixel (dataset) in the left sidebar.
  2. Go to Settings. Scroll to the Conversions API section.
  3. Choose a setup path. Click "Set up integration" (or "Choose a partner") and pick your platform. Log in and authorize the connection.
  4. Select data sharing level. Meta offers options such as standard, enhanced and maximum. Higher levels send more customer parameters and improve matching, so choose the highest your privacy policy and local law allow.
  5. Confirm the pixel. Pick the pixel ID the integration should use, then finish.
  6. Test it. Return to the Test Events tab, place a test order and confirm that events are labeled "Browser" and "Server."
  7. Check Overview. After 24 hours, open the Overview tab and look at the "Connection method" and event coverage indicators.

Menu labels shift as Meta updates the interface, so treat the names above as a guide rather than exact wording.

Option 2: Google Tag Manager server container

A server-side GTM container sends events from a cloud endpoint you control. It gives you flexibility and first-party context, but you'll pay for hosting and someone has to maintain it. Google's server-side tagging documentation covers the setup, and a small store typically spends somewhere around $20–$100 per month on cloud hosting, depending on traffic and provider (treat this as a rough planning range, not a quote). Good for teams with a developer or an agency.

Option 3: direct integration

Your developer posts events to Meta's Graph API endpoint using your pixel ID and an access token generated in Events Manager. This is the most precise option. A minimal purchase payload looks like this:

{
  "event_name": "Purchase",
  "event_time": 1764201600,
  "event_id": "order_10482",
  "action_source": "website",
  "event_source_url": "https://yourstore.com/checkout/thank-you",
  "user_data": {
    "em": ["hashed_email_sha256"],
    "ph": ["hashed_phone_sha256"],
    "client_ip_address": "203.0.113.5",
    "client_user_agent": "Mozilla/5.0 ...",
    "fbp": "fb.1.1700000000.123456789",
    "fbc": "fb.1.1700000000.AbCdEf"
  },
  "custom_data": {
    "currency": "USD",
    "value": 84.50
  }
}

Hash emails and phone numbers with SHA-256 after trimming and lowercasing. Send the raw IP and user agent unhashed. Skipping fields is allowed, but each one you add improves matching. The full field list is in Meta's server event parameters reference.

How to deduplicate Meta Pixel events

To deduplicate Meta Pixel events, send the same event_name and the same event_id from both the browser pixel and the Conversions API. Meta then treats the two as one event and counts it once. Without matching IDs, you'll see inflated purchases.

Developer reviewing order IDs in code beside a printed order list on a desk in a quiet home office

Meta Pixel event deduplication works best when the ID is something stable, like your order number. Here's the pattern:

  1. Generate the ID once. Use the order ID for purchases, or a random UUID created at page load for other events.
  2. Pass it to the pixel. In the browser call: fbq('track', 'Purchase', {value: 84.50, currency: 'USD'}, {eventID: 'order_10482'});
  3. Pass it to CAPI. Use the same value in the event_id field.
  4. Keep the timing close. Meta's deduplication documentation says events with matching IDs received within 48 hours of each other are deduplicated, but sending both within seconds keeps reporting clean.
  5. Verify in Events Manager. The event should show as "Browser and Server" with a deduplication rate.

Common deduplication mistakes

  • Using a different ID format on each side (for example "10482" in the browser and "order_10482" on the server).
  • Sending event names with different capitalization ("purchase" vs "Purchase").
  • Generating a fresh random ID on each page refresh, so the thank-you page creates a new purchase each time.
  • Running two integrations at once, such as a native app plus a manual pixel snippet, so you get double browser events.

A worked example of a duplicate problem

Say a store processed 100 real orders in a week. The pixel caught 70 (the rest were blocked or lost in redirects), and CAPI sent all 100 but without a shared event ID. Meta would record up to 170 purchases, and your reported ROAS would look far better than reality. With matching IDs, Meta merges the 70 overlapping orders and adds the 30 missing ones, landing on the true 100. That is the goal: not more events, but accurate ones.

Meta Pixel standard events to track for ecommerce

For a Facebook pixel ecommerce setup, track the standard events Meta already understands: ViewContent, AddToCart, InitiateCheckout, AddPaymentInfo and Purchase. These map to the funnel Meta optimizes against, and they unlock dynamic product ads and catalog-based retargeting.

Standard eventWhen it firesKey parameters
PageViewEvery page loadNone required
ViewContentProduct page viewcontent_ids, content_type, value, currency
AddToCartItem added to cartcontent_ids, value, currency
InitiateCheckoutCheckout startedvalue, currency, num_items
AddPaymentInfoPayment step submittedvalue, currency
PurchaseOrder confirmedvalue, currency, content_ids

Your product IDs must match your catalog feed exactly, or dynamic ads won't connect events to products. If you're still filling out a catalog, our guide on how to add products to your online store covers the structure that makes this easier. Meta lists every standard event and its parameters in its Meta Pixel reference.

Improve event match quality in Meta

Event Match Quality (EMQ) is a 0–10 score in Events Manager showing how well your event data matches Meta users. Aim for 6 or higher on Purchase; scores of 8 and above are considered strong. Meta's guidance is that more customer parameters mean better matching.

  • Email and phone: the strongest signals. Send both on every purchase.
  • First and last name, city, zip, country: small boosts that add up.
  • fbp and fbc: pass these from browser cookies to the server.
  • External ID: your customer ID, hashed, helps match returning shoppers.
  • IP and user agent: always include them on server events.

A practical tip: check EMQ per event, not just overall. Stores often find Purchase scores well above AddToCart scores, because the customer has typed an email by checkout but not yet while browsing. If AddToCart is low, pass the hashed email for logged-in users and the fbp cookie for everyone else.

Meta Pixel not tracking purchases? How to troubleshoot

If your Meta Pixel purchase event isn't firing, the cause is almost always one of five things: the pixel isn't on the confirmation page, the event fires before the page loads fully, a consent banner blocks it, the order total is missing, or a duplicate pixel is conflicting. Test each in order.

Use Meta Events Manager test events

Open Events Manager, choose your pixel, and go to the Test Events tab. Enter your store URL, place a test order in the opened window, and watch for events. Meta Events Manager test events also let you paste a test code into your CAPI payload as test_event_code, so you can confirm server events arrive without polluting live data. Meta's guide to testing events in Events Manager lists the current diagnostics.

Pair it with the free Meta Pixel Helper Chrome extension to see which pixels load on each page.

A quick checklist

  1. Confirmation page: does the Purchase event fire only after payment succeeds, not on checkout load?
  2. Value and currency: missing parameters cause Meta to discard or misreport the event.
  3. Consent mode: if your cookie banner blocks marketing scripts, the pixel won't fire for those visitors. CAPI can still send events where you have legal consent.
  4. Redirects: payment providers that redirect off-site can drop the browser event. Server events fix this. Stripe or PayPal webhooks are ideal triggers; if PayPal is part of your checkout, see whether offering PayPal increases conversions.
  5. Domain verification: verify your domain in Business Settings so event configuration isn't restricted.
  6. Duplicate pixel installs: remove old snippets left by previous themes or apps.

How much can this reduce Facebook ads CPA?

Results vary by account, and nobody can promise a number. Meta has published case studies on its business site where advertisers adding CAPI to the pixel reported lower cost per result, with improvements often described in the range of 10–20%, but your gain depends on how much data you were losing. The practical way to reduce Facebook ads CPA through tracking is to compare Meta-reported purchases against your store's actual orders before and after setup. If the gap closes, the algorithm has more to learn from, and CPA usually follows.

A simple method: record seven days of Meta-reported purchases and store orders before the change, then seven days after. Divide ad spend by store orders in both periods to get a true blended CPA. This avoids judging results by Meta's numbers alone.

Keep your tracking clean as you scale

Good tracking is maintenance, not a one-time task. Check Events Manager weekly for the first month, then monthly. Watch three numbers: Purchase match quality, deduplication rate and the gap between Meta-reported and store-reported orders.

Also think about where tracking lives. Every app you add to a store is another script that can fire twice or slow your pages. The fewer moving parts, the fewer ways your data breaks. If you're weighing platforms, our ecommerce builder comparison shows how the options handle built-in features versus add-ons, and our look at WooCommerce maintenance cost shows what plugin-heavy setups cost to keep running.

Frequently asked questions

Is the Conversions API free? Yes. Meta doesn't charge for it. Costs come from hosting a server container or paying for a partner tool.

Will CAPI replace the pixel? Not today. Meta recommends running both for the best coverage and matching.

Does it fix iOS 14 tracking completely? No. It recovers events that browsers drop, but it can't track users who haven't given consent where consent is required.

How long until I see results? Events appear within minutes. Optimization gains typically show after a week or two of stable data.

Conclusion: set up CAPI once, then let it work

The Meta Pixel and the Conversions API are partners. Install both, share one event ID, send as many customer parameters as you legally can, and check Test Events before you spend more on ads. Do that, and you'll stop arguing with your dashboards and start trusting them.

If you'd rather not wire this up yourself, Rovela builds stores with the Meta, Google Ads and Klaviyo integrations already included, so your tracking starts working from day one. You can see how it works with the Rovela AI store builder or check the flat monthly pricing.

Your dream store is one sentence away.