Customer Impact

Data & Tracking

Meta Conversions API: how to set up CAPI correctly alongside your Pixel

Copy for AI

The Meta Conversions API (CAPI) sends conversions from your server or CRM straight to Meta.

Think of a lead, a demo request or a purchase.

It’s a server-to-server connection, so it doesn’t depend on what the visitor’s browser passes on.

The verdict: set up the Meta Conversions API alongside the Pixel, never instead of it. Give each event the same ID in browser and server, and test the result in Events Manager.

That way Meta Ads learns from more and better conversion data than the browser alone passes on.

This guide is about the server side. If you first want to understand what the Pixel measures and which events exist, read our explanation of the Meta Pixel.

This article starts where that one stops: how you choose, set up, deduplicate and check CAPI.

What exactly does the Meta Conversions API do?

It connects your own marketing data to the Meta systems that optimise targeting and delivery.

According to Meta’s documentation, that data can come from your server, website platform, app or CRM. Server events are used for measurement, reporting and optimisation, just like Pixel events.

Browser route vs server route

The difference is the route. The Pixel runs in the browser.

That’s where ad blockers, Safari’s tracking restrictions and scripts that fail to load come into play.

CAPI starts on your side: your own server, your server-side tagging container or your CRM. If you’re new to containers, start with what Google Tag Manager is.

Why it matters for B2B

That server route has three consequences that matter for B2B:

  • Fewer missed leads: your server can still report a form the browser didn’t pass on.
  • Conversions outside the website: a lead that becomes an opportunity three weeks later can be sent back.
  • Control over what you share: you decide which fields leave, hashed and all.

So the question isn’t Pixel or CAPI. It’s how you run both cleanly.

Which setup do you choose: partner, Gateway or server-side GTM?

For most B2B teams that also run Google Ads and LinkedIn, server-side GTM is the logical foundation.

Meta names three ways to connect CAPI: a partner integration, the Conversions API Gateway and a direct integration. In practice we see four variants at Belgian and Dutch companies.

The four setups compared

Here’s how they differ:

SetupHow it worksFitsWatch out
Partner integrationYour CMS or shop (Shopify, WooCommerce plugin) sends events itselfWeb shops on a standard platformLittle control over event names and deduplication
Conversions API GatewayA Meta-managed server in your own cloud environmentTeams without their own tagging serverMeta only, no other platforms
Server-side Google Tag ManagerYour GTM server container sends events to Meta, LinkedIn, Google AdsB2B with several ad channelsNeeds hosting and a clean data layer
Direct integration from your CRMYour CRM or backend calls the APIOffline and late conversions (SQL, deal)Development work and maintenance

Why server-side GTM usually wins for B2B

You build one server-side layer and feed every platform from it. How that layer works is covered in our guide to server-side tracking.

Best for: companies that split budget across Meta and Google. Our comparison of Google Ads vs Meta Ads shows why many B2B teams run both.

When the CRM route comes in

If you have late conversions, the CRM route comes into play. Think of a lead that only gets qualified after a sales call.

Watch out: Meta’s parameter documentation states that event_time can be up to 7 days in the past.

So a deal that closes after six weeks can no longer be sent as a website event.

For example, say a demo request comes in on a Monday and sales qualifies it 10 days later. That’s 3 days past the window.

Rule of thumb: one channel means a partner or the Gateway; several channels mean server-side GTM.

How do you set up the Meta Conversions API, step by step?

In seven steps, and the order matters. This is the order we follow on every setup.

Steps 1 to 4: events and IDs

  1. Map your conversions. For B2B that’s usually Lead (form), Schedule or a custom event for a booked demo. A page view isn’t a conversion.
  2. Make sure you have a data layer. Every form pushes an event with the same name and a unique event ID.
  3. Send the same event through the Pixel. The Pixel tag gets the event ID as eventID.
  4. Send the same event through the server. It goes to CAPI with event_name, event_time, event_id, action_source website and event_source_url.

Without that event ID, Meta can’t deduplicate. How to measure forms reliably without a thank-you page is in our guide to form conversions without a thank-you page.

For CRM-heavy teams, setting up lead tracking first saves a lot of rework later.

Step 5: add customer data

Send a hashed email address (em), phone number (ph), the fbp and fbc values, and the visitor’s IP address and user agent.

Meta requires client_user_agent for website events.

It asks you to hash contact details with SHA-256.

But fbp, fbc, IP and user agent aren’t hashed, according to the documentation on customer information parameters.

  1. Respect consent. The server-side tag only fires if the visitor consented to marketing. More on that further down.
  2. Test and check. Use the test event code in Events Manager before you go live. Then monitor deduplication and match quality.

Only then add the next event. Boring is good here.

How does deduplication between Pixel and CAPI work?

Meta counts the event once when browser and server send the same name and ID.

If you send the same event through both routes, Meta receives it twice. Deduplication makes sure it only counts once.

The four rules

The rules are in Meta’s deduplication guide:

  • the Pixel’s eventID must equal the CAPI event_id
  • the Pixel’s event name must equal event_name in CAPI
  • both must arrive within 48 hours of the first event with that ID
  • Meta generally keeps the event that arrived first

Here’s what that looks like for one lead:

DEDUPLICATION Two routes, one conversion BROWSER Pixel: Lead, eventID 8f2a SERVER CAPI: Lead, event_id 8f2a META same name + ID 1 lead counted Different ID, or the second event after 48 hours, and Meta counts two leads.
Pixel and Conversions API send the same event with the same ID; Meta counts it once.

Where the event ID comes from

You create the ID in the browser at the moment the form is submitted.

Then you pass it through the data layer to both the Pixel tag and the server-side tag.

Watch out: a timestamp on its own isn’t a good ID. Two leads in the same second then get the same number.

The fallback method

Meta also describes an alternative using event_name plus fbp or external_id.

It works, but it’s less predictable.

Our approach: we always use an explicit event ID. No guessing.

Which CAPI mistakes do we see most often?

Double counting tops the list, followed by missing customer data.

In the accounts we review, the same six problems keep coming back.

Counting errors

  • Double counting: Pixel and CAPI send the same event without a shared ID.
  • Two sources for one event: a Shopify or WordPress plugin and your server container both send CAPI events.
  • Every form click as Lead: newsletter sign-ups and job applications come in as leads too.

With double counting, leads in Ads Manager double and the cost per lead halves on paper. The algorithm then learns from a distorted picture.

For example, say your CRM shows 20 Meta leads in a week. Ads Manager shows 40. That’s the classic double count.

The rule for sources is simple: one source per event, not two.

When every form counts as a Lead, Meta optimises for the cheapest, not the best. This closely resembles what we describe in cleaning up false conversions.

Data errors

  • No customer data: events without email, fbp or fbc are hard to tie to a person.
  • Wrongly hashed fields: an email with capitals or spaces gives a different hash.
  • Bypassing consent: “it’s server-side, so the banner doesn’t count” is a misunderstanding.

Events without customer data barely count towards optimisation.

For example, “Jan@Example.com ” and “jan@example.com” give two different hashes. Meta then sees two people.

Fix for hashing: normalise first (lower case, spaces removed), then hash. More on consent below.

How do you test whether the Conversions API works?

In five checks, from Events Manager down to your CRM.

Checks in Meta and GTM

  1. Test Events in Events Manager. Enter your test event code in your server-side tag, submit a test form and check both routes arrive.
  2. Deduplication. Your dataset overview shows per event whether browser and server events are deduplicated.
  3. Match quality. Events Manager scores the quality of the customer data per event.
  4. GTM preview. In the web and server container previews, check the event ID is the same in both tags.

If you see two separate events in check 2, the ID or the event name is wrong. If the score in check 3 is low, check whether email, fbp and fbc are being sent.

The Test Events tab is where you start:

Check against your CRM

  1. CRM comparison. Put the number of Meta leads per week next to the leads from Meta in your CRM.

A big gap points to duplicates or missed events. A small gap is normal.

We do a full check of your measurement, including Google Ads and GA4, in a tracking audit. If you want to start yourself, use our conversion tracking audit checklist.

No, not for marketing.

The Belgian Data Protection Authority states that no cookie or tracker may be placed or read without prior information and consent. The only exception is what’s strictly necessary.

In the Netherlands, the Dutch Data Protection Authority (Autoriteit Persoonsgegevens) takes the same line.

Server-side doesn’t change the purpose

That the data runs through your server doesn’t change the purpose: ad measurement and targeting.

So make your server-side tag depend on the same consent as your Pixel.

What CAPI does solve

It recovers the losses that don’t come from refusals:

  • ad blockers
  • browser restrictions
  • scripts that load too late

How to set up your banner and Google signals properly is covered in our guide to Consent Mode v2 and in cookie banner rules in Belgium.

Tip: run our free cookie scanner to see which trackers load before consent.

This article isn’t legal advice: run your setup past your DPO or lawyer.

How do you send CRM data back to Meta?

By storing Meta’s click and browser IDs with every lead, then sending the CRM stage back.

For B2B the real gain isn’t the form, but what happens after it. A lead who never picks up the phone is worth as much to Meta as one who becomes a customer, unless you send the difference back.

Four steps from lead to qualified event

  1. Store the fbc value (from the fbclid in the URL), the fbp cookie and a hashed email with every lead in your CRM.
  2. Decide which CRM stage you send back, for example “qualified” or “demo held”.
  3. Send that stage with action_source system_generated or website, within the window Meta allows.
  4. Optimise your campaigns on that deeper event once there’s enough volume.

Most CRMs already have a ladder of stages you can map to events, such as HubSpot’s lifecycle stages:

HubSpot lifecycle stage definitions from subscriber and lead to MQL, SQL, opportunity and customer, the CRM stages you can send back to the Meta Conversions API HubSpot’s lifecycle stage definitions, checked 18 October 2026. “Sales Qualified Lead” is a typical stage to send back to Meta as a deeper event.

Pick one stage that sales confirms. Marketing shouldn’t fill it in alone.

The same logic as Google Ads

We use the same logic for Google Ads in importing offline conversions from your CRM. For HubSpot and Salesforce specifics, see offline conversions from your CRM.

Google’s counterpart to customer data matching is enhanced conversions for leads.

Cases

At Kaizo we built the Meta measurement on the same booked demo as Google Ads. Both channels optimise on the same event: read the Kaizo tracking case.

And how one broken form listener silenced GA4, Google Ads, Meta and LinkedIn at once is told in the Suivo case.

When do you not (yet) need the Conversions API?

When Meta isn’t a real channel yet, or your leads come in through Lead Ads forms.

If your leads mainly come in through Lead Ads forms inside Facebook and Instagram, CAPI for website forms adds little. Then connecting Lead Ads to your CRM matters more.

At very low volumes, say 5 leads a month, a correct Pixel matters more than a server-side layer. Good event names and clean CRM records come first.

A quick decision table

Your situationWhat to do first
You barely advertise on MetaCorrect Pixel and clean event names
Leads come from Lead Ads formsConnect Lead Ads to your CRM
A handful of leads a monthPixel plus clean CRM records
Meta is a real channel, several platformsServer-side GTM with CAPI

Start there, and add CAPI once Meta becomes a real channel in your Meta Ads approach.

If you advertise on several platforms, also read our guides on LinkedIn Insight Tag, TikTok Pixel and Stape.

Frequently asked questions

What is the difference between the Meta Pixel and the Conversions API?

The Pixel measures in the visitor’s browser, the Conversions API sends events from your server or CRM. Meta recommends using both and deduplicating them with a shared event ID.

Do I need server-side Google Tag Manager for CAPI?

No. A partner integration or the Conversions API Gateway can also work. Server-side GTM is mainly interesting if, besides Meta, you also want to feed Google Ads, LinkedIn or TikTok server-side from one container.

Why do I see duplicate conversions after installing CAPI?

Usually the shared event ID is missing, the event name differs between Pixel and server, or two integrations (for example a plugin and your server container) send the same event.

Can I send offline conversions through the Conversions API?

Yes, as long as the event falls within the window Meta allows. For late B2B conversions, store fbc, fbp and a hashed email address with the lead in your CRM, so Meta can tie the conversion to the right person.

Does CAPI work when a visitor refuses cookies?

Technically the server can send events, but in Belgium and the Netherlands you may not do so for marketing without consent. CAPI mainly recovers losses from ad blockers and browser restrictions, not from refusals.

Ready to set up CAPI properly?

Run one clean event first. Then build from there.

If you want CAPI set up together with your Google Ads, LinkedIn and GA4 measurement, our tracking specialist does it in one server-side setup, tailored and on request.

Get in touch for a first check of your Pixel and server events.

Free website scan

Enter your website and get an automatic scan within minutes, with concrete technical and SEO improvements. No sales pitch.

Where should we send your report?

We only use your details for your scan. No spam, unsubscribe anytime.