Use these best practices as general recommendations to successfully integrate the Conversions API. These recommendations are designed to help you make the most effective use of the Conversions API. Follow the implementation and post-implementation recommendations to ensure a smooth integration and optimal results when sharing data with Facebook.
In addition to the following best practices, we recommend that you watch this video for a more hands-on tutorial on using the Conversions API. The video guides you through how to:
Website events shared using the Conversions API require the following data parameters:
event_source_url, while non-web events require only
action_source. These parameters contribute to improving the quality of events used for ad delivery and may improve campaign performance.
When setting up your campaign, simplify the account structure and use the following established campaign best practices:
We recommend that you use the Conversions API in addition to the Meta Pixel, and that you share the same events using both tools. We call this a redundant event setup. For example, if you share
Initiate Checkout, and
Contact events using the Meta Pixel, you should also share those same events from your server using the Conversions API.
The Conversions API allows you to share website events that the Pixel may lose due to network connectivity issues or page loading errors. The Conversions API can also be used to share other types of important events and data that occur offline or at a later time that the Pixel cannot.
When sending redundant events using the Meta Pixel and Conversions API, ensure that both events use the identical
event_name and that either
event_id or a combination of
fbp are included. We recommend including all of these parameters to help Facebook properly deduplicate events and reduce double reporting of identical events. Learn more about deduplication, when it’s necessary and how to set it up.
All website events
All website events
We also recommend including the
event_id event parameters for all events.
Sending additional customer information parameters may help increase Event Match Quality. Only matched events can be used for ads attribution and ad delivery optimization, and the higher the matching quality, the better. While unmatched events cannot be used for attribution or ad delivery optimization, they can still be used for basic measurement. Examples of high-quality customer information parameters include:
Following the release of Graph API version 13.0, we will be updating the baseline requirements for which combinations of customer information parameters are considered valid with a Conversions API event. These changes will help us provide better feedback for when an event has a combination of customer information parameters that is so broad that it is unlikely to be effective for matching.
An event is considered invalid if it only includes customer information parameters that consist of one of the following combinations, (or a subset thereof).
For example, if an event had only the customer information parameters
country (this could correspond to a man, in Menlo Park, California, USA), it would be rejected because those customer information parameters are a subset of one of the above combinations.
fbcParameters Are Refreshed
fbc parameters are cookie values typically set on your site visitors’ browsers in connection with Facebook’s first-party cookie solution, and are subject to change. If you send them as user parameters, you should regularly refresh their values.
These values will be set as first-party cookies when the Meta Pixel is implemented on your website and can be retrieved for use in Conversions API requests.
Sharing events when they happen can help your campaigns achieve the best results. You can share server events using the Conversions API in real time or in batches close to real time.
We recommend using the Test Events tool to validate your Conversions API connection. Typically, developers should use their own customer information parameters (for example, name, email address, phone number) for test events, because these events may get discarded if they don't match a Facebook account.
You can use the Test Events tool to:
Fill out the required and recommended data parameter fields in the Payload Helper tool to see how your payload should be structured and to get recommendations for which parameters to include.
The code samples in our documentation include Business SDK examples in Python, Java, Ruby, PHP, and Node. They can save some development effort, such as hashing user parameters, which is done automatically in the Business SDK.
If you are not planning to use the Business SDK, we recommend that you implement hashing.
The Conversions API supports all offline events, except for physical store sales, and should be used as the comprehensive container for these types of events. Examples include phone calls, actions taken on devices (such as smart TVs or game consoles), and offline subscriptions.
When sending offline events, be sure to include the
action_source event parameter, and choose the appropriate value (should not be
website). The action source is required to determine the campaign objectives for which the event is intended.
If your campaign objective is store sales, use the Offline Conversions API to share physical store sales or store visits. Events shared using this API go to a different offline event set container, and are specifically used for the store sales campaign objective.
Partners or agencies that share events on behalf of their advertisers should send a unique
partner_agent string, including platform name as documented. If applicable, work with your dedicated Facebook representative to decide on a suitable agent string.
By default, website platform partners may consider whether to offer Conversions API selectively or to opt-in advertisers. The Meta Pixel and Conversions API share the same business terms, and we recommend that you opt-in your customers to also share their data using the Conversions API when they set up the Meta Pixel. While we believe using both tools will strengthen and secure their data-sharing for the long term, we also suggest that you provide your customers with information about both the Conversions API and Meta Pixel to help inform their choice.
If you share server events using the Conversions API, you can see the Event Match Quality (EMQ) for each event in Events Manager. An event’s EMQ score (out of 10) indicates how effective your server event’s customer information may be at matching it to a Facebook account. One of the easiest and most effective ways to improve EMQ is to include
client_user_agent with all of your website events.
When using the Conversions API, we recommend that you test and optimize your Facebook advertising strategy. Some testing options include: