> Site index: https://usehardal.com/llms.txt
> Every content route also serves markdown at <url>.md

# What Is the Meta Conversions API (CAPI)?

The Meta Conversions API (CAPI) lets a server send web, app, and offline events to Meta, usually alongside the Meta Pixel with shared event IDs.

Source: https://usehardal.com/glossary/meta-conversions-api

---

The Meta Conversions API (CAPI) is Meta's server interface for receiving marketing events. Instead of relying only on the Meta Pixel in the visitor's browser, your server sends events such as `Purchase` or `Lead` directly to Meta. Meta uses them for measurement, attribution, and ad delivery, the same as Pixel events.

CAPI is not a separate tracking system. It is a second delivery path for the same actions, plus a way to report events that never happen in a browser, such as a phone sale or a CRM status change.

## How does the Meta Conversions API work?

Your server sends an HTTPS `POST` to the Graph API events endpoint for your dataset (Pixel ID), with an access token. Each event in the `data` array carries a few core fields.

- `event_name`, such as `Purchase`, `Lead`, or a custom name.
- `event_time`, a Unix timestamp in seconds.
- `event_id`, a unique ID that matches the Pixel's `eventID` for the same action.
- `action_source`, such as `website`, `app`, or `physical_store`.
- `event_source_url` and `client_user_agent`, which web events require.
- `user_data`, the customer information Meta uses to match the event to a person.
- `custom_data`, such as `value`, `currency`, and `content_ids`.

Inside `user_data`, personal fields such as `em` (email) and `ph` (phone) are normalized and hashed with SHA-256 before sending. The `fbp` and `fbc` cookie values, `client_ip_address`, and `client_user_agent` are sent as they are.

## A concrete example

A shopper pays for order `A-1042`. The browser fires `fbq('track', 'Purchase', {value: 80, currency: 'EUR'}, {eventID: 'A-1042'})`. Your order service also sends a CAPI event with `event_name` set to `Purchase` and `event_id` set to `A-1042`, plus the hashed email and the `fbp` value captured at checkout. Meta sees two copies with the same name and ID, keeps one, and counts one purchase. Meta's [deduplication documentation](https://developers.facebook.com/docs/marketing-api/conversions-api/deduplicate-pixel-and-server-events) says this applies when both copies reach the same Pixel ID within 48 hours.

## Why it matters

Meta can only attribute and optimize on events it receives and can match to an account. A server path keeps reporting when a browser request is blocked or the tab closes before the Pixel fires. The quality of the customer information you send is scored as [Event Match Quality](https://usehardal.com/glossary/event-match-quality).

## Common pitfalls

- **Missing or random event IDs.** If the Pixel and the server generate different IDs, Meta counts the purchase twice.
- **Wrong timestamp format.** `event_time` is in seconds, not milliseconds and not an ISO string.
- **Hashing the wrong fields.** Hashing `fbp` or the IP address breaks matching. Not hashing the email breaks Meta's data rules.
- **Sending events without consent.** The server must respect the same consent choice the browser received.
- **Mismatched values.** If the Pixel sends gross revenue and the server sends net revenue, reports drift and nobody knows which is right.

## How Hardal helps

Hardal is the first-party data and agentic analytics platform. It sends server-side events to the [Meta Conversions API](https://usehardal.com/destinations/meta) from your own first-party subdomain, keeps one event ID per action for deduplication, and can combine website events with CRM data. To serve the endpoint from your own domain, see the [first-party domain setup for Meta CAPI](https://usehardal.com/how-to-set-up-first-party-domain-for-meta-capi). To raise match rates, read [How to Improve Meta CAPI Event Match Quality](https://usehardal.com/improve-meta-capi-event-match-quality).

**Related terms:** [Event Match Quality](https://usehardal.com/glossary/event-match-quality), [Event deduplication](https://usehardal.com/glossary/event-deduplication), [Server-side measurement](https://usehardal.com/glossary/server-side-measurement), [First-party data](https://usehardal.com/glossary/first-party-data)
