Configuring Facebook's Conversions API with Server-Side Container Setup

Configuring Facebook's Conversions API with Server-Side Container Setup

Facebook's Conversions API allows you to share key web and offline events or customer actions directly from your server to Facebook's. This is becoming increasingly important for successful ad performance tracking due to browser limitations on cookies. In this guide, we will cover the process of setting up a server-side container to configure Facebook's Conversions API.


Step 1: Create a Facebook App


First, you need to have a Facebook app. Follow these steps to create a new app:


Go to Facebook Developers website [https://developers.facebook.com/]

Click on "My Apps" then "Create App".

Choose "Manage Business Integrations", which is designed for apps that allow other businesses to manage their assets.

Follow the remaining prompts to create your app.


Step 2: Set Up the Conversions API in Your App


Go to your app dashboard on the Facebook Developers website.

From the navigation panel, choose "Products" > "+ Add Product" > "Conversions API" > "Set up".


Step 3: Install Facebook Business SDK


Facebook's Business SDK includes the Conversions API and is essential for sending server events. Choose your server's language and follow the instructions provided to install the SDK .


Step 4: Configure the Access Token


To send events to Facebook from your server, you need an access token:


Go to your app dashboard.

Click on "Marketing API" > "Tools".

Under "User or System User Tokens", click "Get Token".

Save this token. You will use it when configuring your server-side container.

Step 5: Set Up Server-Side Container

For this part, we'll use Google Tag Manager's server-side tagging, which allows you to move third-party tags off your website and onto your server.


Start by creating a Google Cloud account [https://cloud.google.com/], if you don't have one already.

Then, create a new project in the Google Cloud Console [https://console.cloud.google.com/].

After that, go to your Google Tag Manager account [https://tagmanager.google.com/] and create a new server container.

Follow Google's guide to link your new Google Cloud project to the server container.


Step 6: Install Facebook Server-Side Tag in Google Tag Manager


In your server-side container in Google Tag Manager, click "Tags" > "New".

For the Tag type, select "Facebook Server Event".

For the Access token, enter the token from step 4.

Click "Save".


Step 7: Send Test Event from Your Server


Use Facebook's test event tool to send a test event from your server:


Go to the Events Manager on Facebook.

Select your pixel.

Click "Test Events".

Enter your website URL and click "Open Website".

Use your site and create an event (like a purchase).

Verify that the event shows up in the "Test Events" tab.

Congratulations, you have now set up Facebook's Conversions API using a server-side container!


Please note that the specifics of your setup might vary based on your server setup and the programming language you are using.


 Facebook also provides more detailed instructions and other useful resources in their Conversions API Documentation.


Remember, if you need further assistance , don't hesitate to reach out to our support team or visit Facebook's Help Center. Keep in mind that changes in your server setup or Facebook's API could require adjustments in your configurations.


Facebook's Conversions API, combined with Facebook Pixel, can provide a more complete picture of your customer interactions and help you improve your marketing strategy. Continue to monitor and refine your setup to better track and understand your customer conversions.


If you're looking to integrate with other systems or further customize your setup, consider exploring Facebook's Partner Integrations. These pre-built solutions can make it easier to connect Facebook's Conversions API with other parts of your business.
    • Related Articles

    • Setting Up Google Analytics 4 for Your Website

      Google Analytics is a powerful tool that can provide insights into how visitors interact with your website. In October 2020, Google released Google Analytics 4 (GA4), which offers advanced features and more flexible tracking capabilities than ...
    • Updating DNS Records

      DNS, or Domain Name System, is the protocol that translates domain names to IP addresses, directing traffic to the correct server when a user types in a website address. When you change your hosting provider, you may need to update your DNS records ...
    • Setting Up Cloudflare for Your Domain on VPS or Dedicated Hosting

      Cloudflare is a popular service that enhances your website's performance and security. It acts as a Content Delivery Network (CDN), optimizes the delivery of your web pages, and protects your site from malicious activities. In this guide, we'll walk ...
    • How to Improve Your WordPress Website Speed Scores

      Website speed plays a crucial role in user experience and SEO. A slow-loading site can lead to high bounce rates, low user engagement, and poor search engine rankings. Fortunately, WordPress offers many tools and techniques to optimize your website ...
    • Maintaining PCI Compliance on WooCommerce and Shopify Ecommerce Websites

      The Payment Card Industry Data Security Standard (PCI DSS) is a set of security standards designed to ensure that all companies that accept, process, store, or transmit credit card information maintain a secure environment. This guide outlines how to ...