An order was placed in the online store, but Meta cannot see it. At other times it sees it twice. The team then tunes campaigns using numbers it does not trust, and the first idea is: let’s implement CAPI and it will fix everything.
Conversions API can make measurement more accurate because it sends some marketing events from the server, CRM or platform directly to Meta’s systems. But it will not restore data the company never creates, nor will it fix poorly named conversions. First, you need a measurement plan. Only then comes data transfer.
CAPI is not a replacement for the Pixel or consent
Meta describes Conversions API as a more direct connection between a company’s marketing data and its systems for measuring and optimising ads. For web events, it recommends considering CAPI together with the Meta Pixel. Browser-side and server-side paths can complement one another.
That does not mean the server may send everything the browser did not send. Meta explicitly states that CAPI is not designed to circumvent privacy rules, European regulations or platform restrictions. Handle consent and the lawfulness of processing according to the specific data, region and legal assessment. A hashed email is still data derived from a person, not a smokescreen.
First decide which events have business value
For an online store, it usually makes sense to track the path from viewing a product through the basket and checkout to purchase. For a lead-generation website, a submitted form or qualified lead may matter more. I would not send every click as a conversion simply because you can.
For every event, write down:
- what exactly must happen in the real world,
- whether it is the main business outcome or merely a diagnostic signal,
- which system is the source of truth,
- which unique identifier you will use,
- which parameters advertising and reporting need,
- under which conditions you are allowed to send the data.
For a purchase, the source of truth is often the confirmed order in the online store or backend, not merely opening the thank-you page. For a lead, the form may be the first signal, but only the CRM confirms the contact’s quality.
Deduplication determines whether double measurement helps
When you send the same event from both the Pixel and the server, Meta must recognise it as one event. This requires the same event name and the same event_id on both paths.
For a purchase, a stable order ID can be a suitable basis. For an event without its own business ID, create a unique identifier when the action occurs and pass it to both the browser and server layers. A random identifier generated separately on each side will not help — the values will not match.
Deduplication is not a detail for a developer. If it fails, campaigns may receive a double signal and reporting will start to lie.
Four implementation paths have different costs
A partner or an e-commerce platform feature
For a typical online store, this is often the first choice. The platform maintains the integration continuously and the company does not have to own API code. Still, check which events it sends, whether it handles deduplication and consent, and whether it lets you inspect the parameters.
A managed service or gateway
A provider takes over part of the infrastructure and updates. You pay for operations and dependency, but reduce your own technical maintenance. It makes sense if the service supports your stack and you have clear access to diagnostics.
Server-side Google Tag Manager
A server container can unify several marketing data transfers and give the company more control. At the same time, it adds hosting, templates, permissions and another place that needs testing. I would not choose it merely for a nice architecture diagram.
A custom direct integration
It has the greatest flexibility and also the greatest responsibility. You need secure token management, input validation, logging without leaking sensitive data, recovery from errors, API version management, and someone who will maintain the integration.
The original article offered a short PHP script and a publicly accessible endpoint. I no longer recommend such a solution as a general guide. It contained an old API version and too many security and operational assumptions. Code that works today after being copied may silently drop events tomorrow. For a direct integration, work from Meta’s current documentation and do normal development, not copy-and-paste marketing.
Event quality matters more than the number of parameters
A server-side event typically needs a name, time, action source and URL or other context depending on the source. For a business event, add the relevant value, currency, items and stable ID. Send user identifiers only when you are entitled to have them, they are correctly normalised, and they are in the required format.
More identifiers can improve matching, but “the more, the better” is not true without limits. Do not send empty, made-up or outdated values. And certainly do not create a fingerprint to circumvent the user’s choice.
The test must cover the entire journey
- Start test mode in Meta Events Manager.
- Complete a real scenario from entering the website through to an order or lead.
- Verify the browser-side and server-side events, their parameters and matching IDs.
- Check that Meta deduplicates the pair and does not display a diagnostic error.
- Compare the value, currency and ID with the backend or CRM.
- Test both granting and refusing consent according to your solution.
- After deployment, monitor diagnostics and drops over time, not just one green test.
Test Events confirms that the technical message arrived. It does not confirm that you selected the correct conversion or that the integration is legally compliant.
CAPI and GA4 are two different layers
CAPI sends events to Meta for its measurement and advertising optimisation. GA4 analyses the website and app across sources. The numbers may differ because of attribution, consent, identity and processing. I do not try to force them into an absolute match; first I verify that each system receives technically correct data and that we use it for the right decision.
If you need a shared overview of costs and website results, also read connecting Meta Ads with GA4. The Google Tag Manager guide covers tag implementation itself, and the GA4 guide explains the meaning of events.
When I would not implement CAPI yet
If the company has not defined its conversions, does not know which order is valid, or cannot maintain its current Pixel, adding a server-side path will increase the chaos. First fix the source data and measurement plan. CAPI makes sense when you know which signal you want to deliver, why Meta needs it and who will own the integration.
If you want to choose the smallest sensible solution for your online store or lead-generation website, send me the platform, current measurement setup and the event that matters most to your business through contact.