Measure server side conversions on Facebook with the Meta Conversion API
For the Meta Conversion API to work, you must first configure a server container. Visit this blog to find out how to set this up.
In the first blog of the implementation series, we showed how to install the Meta pixel via Google Tag Manager, client side. Now that all events are sent through the Meta pixel client side, we want to send the events that are missed (due to blocking from browsers and ad blockers) server side. This can be done with the conversion API. But how do you set it up? We will show you in this blog.
Meta works a little differently than other tags. You send both client side (Meta pixel) and server side (Conversion API) data to the platform. Through deduplication, Facebook can distinguish the unique requests and collect as much data as possible.
Curious about the entire Facebook Server Side Tracking setup? Then check out this page.
Most companies are used to working with the Meta pixel. In this blog, we will assume that it is already installed. You will learn how to install the Conversion API yourself.
Meta Conversion API setup Google Tag Manager
1: Select Pixel
Go to the company settings in your company manager. Select your company and click on 'Data sources'. Next, select 'Pixels.
2. Generate access tokens
Click on 'Open in Event Manager' in the upper right corner . Then go to settings and scroll down until you see the 'Generate Access Token' button. Click it and the access token will be created. Next, copy this token.
3. Create Tag
Now that the access token has been generated, we can start creating the tag in Google Tag Manager. Go to the server container in Google Tag Manager. Go to 'Tags' and then click on 'New'. Not created a server container yet? Then check out this blog.
4. Tag configuration
Click on 'Tag configuration. Under 'Choose tag type', click 'Discover more tag types in the templategallery....'. In the template gallery, search for conversion API and select: Facebook Conversion API.
5. Set Tag
Under 'Event name setup method', select : Inherit from client. Paste the access token you generated in step 2 under 'API Access token'. Next, enter your Facebook Pixel ID . Not created and installed a Meta Pixel yet? Then visit this blog.
6. Fill in the triggers
Once the tag is set up we are going to choose the trigger, or in other words at what time the tag should be fired. In this case, we would like the tag to forward all GA4 events to Facebook. The tag automatically matches specific GA4 events with standard Facebook events. In other words:
view_item = viewContent
add_to_cart = addToCart
etc..
This way, you have all GA4 events available to you in Meta as well. To forward all GA4 events, you can choose the GA4 client trigger. Don't have this trigger set up yet? Check out the GA4 Client Trigger blog.
5. Save Tag
Give the new tag a name, for example, "Facebook Conversion API" and click "Save.
6. Checking Business Manager
To see if the Facebook Conversion API is working you can go to the Events Manager --> Pixel --> click on an event. Here you will then see 2 lines running, the events from the browser (Client Side) and the events from the Server (Server Side).
The Meta Conversion API is now set up, nicely done! The Facebook events are now measured server side. Currently, Facebook does not distinguish between events from the pixel (client side) and from the conversion API (server side). To remove these duplicate measurements you can use event deduplication. This is the next and final step in the Facebook implementation series.
Frequently asked questions Facebook Conversion API
Should the names of conversions in GA4 and Facebook be the same?
Yes, it is necessary for the names of conversions in GA4 (Google Analytics 4) and Facebook to be the same.