How to add Facebook Pixel to Google Tag Manager
Prerequisites for adding a Facebook pixel to Google Tag Manager
- You have a Google Tag Manager account.
- Google Tag Manager is installed on your website.
- You have the publish permission at the GTM container level.
- You have an active Facebook Business Manager account.
- You have at least one Facebook ad account which is linked to your Facebook business manager account.
- You have the ‘Manage Ad Account’ access for the Facebook ad account.
Follow the steps below to add the Facebook pixel to Google Tag Manager:
Step-1: Make sure that you are already logged in to your Google Tag Manager account and that you have the ‘Publish’ permission at the container level:
Step-2: Navigate to your Facebook Business Manager account https://business.facebook.com/settings/ad-accounts/
Step-3: Navigate to the business/client for which you want to set up the Facebook pixel tracking:
Step-4: Make sure you have ‘Manage Ad Account‘ access
Step-5: Click on the ‘All Tools’ drop-down menu:
Step-6: Click on the shortcut named ‘Events Manager’:
If your Facebook pixel is not already set up then follow the steps below, otherwise jump to step-13:
Step-7: You will be asked to create a new data source: Click on ‘Connect a Data Source’.
Step-8: An overlay will appear like below, select ‘Web’ and then click on ‘Connect’.
Step-9: Give a name to your Facebook pixel and then click on the ‘Create Pixel’ button:
Now you have created your Facebook pixel
Step-10: Enter your website URL in the text box and then click on the ‘Check’ button:
Step-11: Click on the ‘Next’ button:
Step-12: Click on ‘Pixel Only’ and then click on the ‘Next’ button:
Now jump to step-16
Step-13: Click on your Facebook pixel:
Step-14: Click on the ‘Manage Integrations’ button:
You should now see a dialogue box like the one below:
Step-15: Click on the ‘Manage’ drop-down menu next to ‘Browser pixel’ and then click on ‘Add to another website’:
You should now see a window like the one below:
Step-16: Click on the ‘Use a partner’ button:
Step-17: Click on ‘Google Tag Manager’:
Step-18: Click on the ‘Next’ button:
Step-19: Click on your Google account:
You should now see a window like the one below:
Step-20: Scroll down the window and then click on the ‘Allow’ button:
Step-21: Select your Google Tag Manager account from the ‘Account’ drop-down menu and your container from the ‘Container’ drop-down menu:
Step-22: Click on the ‘Finish setup’ button:
Once you click on the ‘Finish setup’ button, Facebook will automatically create a new tag in your Google Tag Manager container and publish the version live.
Step-23: Navigate back to your Facebook events manager and then click on the ‘Next’ button:
Step-24: Click on the button ‘Test events in Events Manager’:
You should now see a new tab opened in your browser window like the one below:
Step-25: Click on the ‘Test events’ tab:
Step-26: Scroll down the screen, enter your website URL in the text box and then click on the ‘Open website’ button:
Your website should now open in a new tab in your browser window.
Step-27: Navigate to different pages on your website.
Step-28: Navigate back to your Facebook events manager. You should now see the events being recorded:
Step-29: Navigate back to the browser tab which shows the window ‘Connect your Google Tag Manager account to Facebook’ and then click on the ‘Finish’ button:
Step-30: Navigate to ‘Apps with access to your account’: https://myaccount.google.com/permissions
Step-31: Find and click on ‘FB Pixel Installation’:
Step-32: Click on the ‘REMOVE ACCESS’ button so that Facebook can no longer access, manage or publish your GTM container versions:
That’s how you can add Facebook Pixel to Google Tag Manager.
If you want to track website/Mobile App conversions (like ‘sales’, ‘leads’, ‘signups’, ‘add to cart’, etc) generated by Facebook users on your website in your Facebook advertising account then you need to deploy the ‘Facebook pixel code’ on all of your website pages.
Another advantage of deploying the ‘Facebook pixel code’ on your website is, you can then create ‘custom audiences’ in your Facebook Advertising account. Through custom audiences, you can remarket your website users on Facebook.
In this article, I will show you, how to test and deploy the Facebook pixel code and Facebook event code on your website via Google Tag Manager.
Get weekly practical tips on GA4 and/or BigQuery to accurately track and read your analytics data.
Other articles on Facebook Pixel Tracking
- facebook.com Referral Traffic in Google Analytics Explained
- Facebook Attribution and Conversion Windows Tutorial
- Facebook ROI Calculation, Analysis and Examples
- How to set up the Facebook Attribution Tool
- How to Setup Funnels in Facebook Ads Manager
- How to use funnels for your Facebook Ad Campaigns
- How to advertise on Facebook for FREE with unlimited budget
- Facebook Pixel vs Google Analytics Data Discrepancies
- facebook.com Referral Traffic in Google Analytics Explained
- Send Facebook Pixel Purchase Event via Google Tag Manager
- Open Graph Protocol for Facebook Explained with Examples
- Tracking Facebook ‘Likes’ and ‘Unlikes’ in Google Analytics
- Google Analytics for Facebook Tutorial
- Facebook Attribution Models Tutorial
- GTM Server Side Tagging for Facebook Tutorial
- The impact of Apple IOS 14.5 update on Facebook Ads
- How to add Facebook Pixel to WordPress Website
- How to add Facebook Pixel to WordPress without a Plugin
- How to track Facebook events via Google Tag Manager
- How to use the Facebook Event Setup Tool
- How to use the Facebook Pixel Helper to Test Facebook Events
- How to automatically turn off Facebook ads on weekends
- How to name Facebook Ad Campaigns like a Pro
Other articles on specialized tracking in Google Analytics
- How to see Organic Search Keywords in GA4 (Google Analytics 4)
- Google Analytics Ecommerce Tracking Tutorial
- Google Tag Manager Event Tracking Tutorial
- Google Analytics Event Tracking Tutorial
- Google Analytics Store Visits Tracking Tutorial
- Offline Conversion Tracking in Google Analytics – Tutorial
- Ecommerce Tracking Google Tag Manager (GTM) – Tutorial
- Tracking Virtual Pageviews in Google Tag Manager – Tutorial
- Google Tag Manager YouTube Video Tracking
- Google Analytics Virtual Pageviews Tutorial
- Google Analytics YouTube Integration & Analysis Tutorial
- Google Analytics for Facebook Tutorial
- Cross Domain Tracking in Google Analytics – Complete Guide
- How to use two Google Analytics codes on one page
- How to correctly use referral exclusion list in Google Analytics
- Google Analytics Calculated Metrics – Tutorial
- Creating your own Google Analytics Tag Auditing System
- Google Tag Manager Search Tracking without Query Parameter
- Tracking Google Analytics Paypal Referral and other payment gateways
- How to Track Phone Calls in Google Analytics 4 – Call Tracking Tutorial
- How to track leads in Google Analytics via CRM
- Postbacks in Google Analytics Explained
- Subscription & Recurring Revenue Analytics in Google Analytics
- Track the Impact of Google Analytics Cookie Consent on Website Traffic
- Tracking Offline Conversions in Google Ads
- Implementing Scroll Tracking via Google Tag Manager
- Scroll Depth Tracking in Google Tag Manager – Tutorial
- Site Search Tracking In Google Analytics Without Query Parameters
- Google Tag Manager Youtube Video Tracking via YouTube Video Trigger
- How to Correctly Measure Conversion Date & Time in Google Analytics
- Google Analytics Social Tracking – Twitter, Facebook, Google Plus and LinkedIn
- Cross Domain Tracking in Google Analytics – Complete Guide
- Google Analytics Linkedin & Twitter Tracking
- Creating Content Group in Google Analytics via tracking code using gtag.js
- Google Analytics Site Search Tracking via Query Parameters
- Google Analytics Site Search Tracking Tutorial
- Creating and Using Site Search Funnel in Google Analytics
- How to add Facebook Pixel to Google Tag Manager
- AMP Google Analytics Tracking – Learn to track AMP pages
- Setting up Sales Funnel across websites in Google Analytics
- Google Analytics 4 Regex (Regular Expressions) Tutorial
Prerequisites for adding a Facebook pixel to Google Tag Manager
- You have a Google Tag Manager account.
- Google Tag Manager is installed on your website.
- You have the publish permission at the GTM container level.
- You have an active Facebook Business Manager account.
- You have at least one Facebook ad account which is linked to your Facebook business manager account.
- You have the ‘Manage Ad Account’ access for the Facebook ad account.
Follow the steps below to add the Facebook pixel to Google Tag Manager:
Step-1: Make sure that you are already logged in to your Google Tag Manager account and that you have the ‘Publish’ permission at the container level:
Step-2: Navigate to your Facebook Business Manager account https://business.facebook.com/settings/ad-accounts/
Step-3: Navigate to the business/client for which you want to set up the Facebook pixel tracking:
Step-4: Make sure you have ‘Manage Ad Account‘ access
Step-5: Click on the ‘All Tools’ drop-down menu:
Step-6: Click on the shortcut named ‘Events Manager’:
If your Facebook pixel is not already set up then follow the steps below, otherwise jump to step-13:
Step-7: You will be asked to create a new data source: Click on ‘Connect a Data Source’.
Step-8: An overlay will appear like below, select ‘Web’ and then click on ‘Connect’.
Step-9: Give a name to your Facebook pixel and then click on the ‘Create Pixel’ button:
Now you have created your Facebook pixel
Step-10: Enter your website URL in the text box and then click on the ‘Check’ button:
Step-11: Click on the ‘Next’ button:
Step-12: Click on ‘Pixel Only’ and then click on the ‘Next’ button:
Now jump to step-16
Step-13: Click on your Facebook pixel:
Step-14: Click on the ‘Manage Integrations’ button:
You should now see a dialogue box like the one below:
Step-15: Click on the ‘Manage’ drop-down menu next to ‘Browser pixel’ and then click on ‘Add to another website’:
You should now see a window like the one below:
Step-16: Click on the ‘Use a partner’ button:
Step-17: Click on ‘Google Tag Manager’:
Step-18: Click on the ‘Next’ button:
Step-19: Click on your Google account:
You should now see a window like the one below:
Step-20: Scroll down the window and then click on the ‘Allow’ button:
Step-21: Select your Google Tag Manager account from the ‘Account’ drop-down menu and your container from the ‘Container’ drop-down menu:
Step-22: Click on the ‘Finish setup’ button:
Once you click on the ‘Finish setup’ button, Facebook will automatically create a new tag in your Google Tag Manager container and publish the version live.
Step-23: Navigate back to your Facebook events manager and then click on the ‘Next’ button:
Step-24: Click on the button ‘Test events in Events Manager’:
You should now see a new tab opened in your browser window like the one below:
Step-25: Click on the ‘Test events’ tab:
Step-26: Scroll down the screen, enter your website URL in the text box and then click on the ‘Open website’ button:
Your website should now open in a new tab in your browser window.
Step-27: Navigate to different pages on your website.
Step-28: Navigate back to your Facebook events manager. You should now see the events being recorded:
Step-29: Navigate back to the browser tab which shows the window ‘Connect your Google Tag Manager account to Facebook’ and then click on the ‘Finish’ button:
Step-30: Navigate to ‘Apps with access to your account’: https://myaccount.google.com/permissions
Step-31: Find and click on ‘FB Pixel Installation’:
Step-32: Click on the ‘REMOVE ACCESS’ button so that Facebook can no longer access, manage or publish your GTM container versions:
That’s how you can add Facebook Pixel to Google Tag Manager.
If you want to track website/Mobile App conversions (like ‘sales’, ‘leads’, ‘signups’, ‘add to cart’, etc) generated by Facebook users on your website in your Facebook advertising account then you need to deploy the ‘Facebook pixel code’ on all of your website pages.
Another advantage of deploying the ‘Facebook pixel code’ on your website is, you can then create ‘custom audiences’ in your Facebook Advertising account. Through custom audiences, you can remarket your website users on Facebook.
In this article, I will show you, how to test and deploy the Facebook pixel code and Facebook event code on your website via Google Tag Manager.
Other articles on Facebook Pixel Tracking
- facebook.com Referral Traffic in Google Analytics Explained
- Facebook Attribution and Conversion Windows Tutorial
- Facebook ROI Calculation, Analysis and Examples
- How to set up the Facebook Attribution Tool
- How to Setup Funnels in Facebook Ads Manager
- How to use funnels for your Facebook Ad Campaigns
- How to advertise on Facebook for FREE with unlimited budget
- Facebook Pixel vs Google Analytics Data Discrepancies
- facebook.com Referral Traffic in Google Analytics Explained
- Send Facebook Pixel Purchase Event via Google Tag Manager
- Open Graph Protocol for Facebook Explained with Examples
- Tracking Facebook ‘Likes’ and ‘Unlikes’ in Google Analytics
- Google Analytics for Facebook Tutorial
- Facebook Attribution Models Tutorial
- GTM Server Side Tagging for Facebook Tutorial
- The impact of Apple IOS 14.5 update on Facebook Ads
- How to add Facebook Pixel to WordPress Website
- How to add Facebook Pixel to WordPress without a Plugin
- How to track Facebook events via Google Tag Manager
- How to use the Facebook Event Setup Tool
- How to use the Facebook Pixel Helper to Test Facebook Events
- How to automatically turn off Facebook ads on weekends
- How to name Facebook Ad Campaigns like a Pro
Other articles on specialized tracking in Google Analytics
- How to see Organic Search Keywords in GA4 (Google Analytics 4)
- Google Analytics Ecommerce Tracking Tutorial
- Google Tag Manager Event Tracking Tutorial
- Google Analytics Event Tracking Tutorial
- Google Analytics Store Visits Tracking Tutorial
- Offline Conversion Tracking in Google Analytics – Tutorial
- Ecommerce Tracking Google Tag Manager (GTM) – Tutorial
- Tracking Virtual Pageviews in Google Tag Manager – Tutorial
- Google Tag Manager YouTube Video Tracking
- Google Analytics Virtual Pageviews Tutorial
- Google Analytics YouTube Integration & Analysis Tutorial
- Google Analytics for Facebook Tutorial
- Cross Domain Tracking in Google Analytics – Complete Guide
- How to use two Google Analytics codes on one page
- How to correctly use referral exclusion list in Google Analytics
- Google Analytics Calculated Metrics – Tutorial
- Creating your own Google Analytics Tag Auditing System
- Google Tag Manager Search Tracking without Query Parameter
- Tracking Google Analytics Paypal Referral and other payment gateways
- How to Track Phone Calls in Google Analytics 4 – Call Tracking Tutorial
- How to track leads in Google Analytics via CRM
- Postbacks in Google Analytics Explained
- Subscription & Recurring Revenue Analytics in Google Analytics
- Track the Impact of Google Analytics Cookie Consent on Website Traffic
- Tracking Offline Conversions in Google Ads
- Implementing Scroll Tracking via Google Tag Manager
- Scroll Depth Tracking in Google Tag Manager – Tutorial
- Site Search Tracking In Google Analytics Without Query Parameters
- Google Tag Manager Youtube Video Tracking via YouTube Video Trigger
- How to Correctly Measure Conversion Date & Time in Google Analytics
- Google Analytics Social Tracking – Twitter, Facebook, Google Plus and LinkedIn
- Cross Domain Tracking in Google Analytics – Complete Guide
- Google Analytics Linkedin & Twitter Tracking
- Creating Content Group in Google Analytics via tracking code using gtag.js
- Google Analytics Site Search Tracking via Query Parameters
- Google Analytics Site Search Tracking Tutorial
- Creating and Using Site Search Funnel in Google Analytics
- How to add Facebook Pixel to Google Tag Manager
- AMP Google Analytics Tracking – Learn to track AMP pages
- Setting up Sales Funnel across websites in Google Analytics
- Google Analytics 4 Regex (Regular Expressions) Tutorial
My best selling books on Digital Analytics and Conversion Optimization
Maths and Stats for Web Analytics and Conversion Optimization
This expert guide will teach you how to leverage the knowledge of maths and statistics in order to accurately interpret data and take actions, which can quickly improve the bottom-line of your online business.
Master the Essentials of Email Marketing Analytics
This book focuses solely on the ‘analytics’ that power your email marketing optimization program and will help you dramatically reduce your cost per acquisition and increase marketing ROI by tracking the performance of the various KPIs and metrics used for email marketing.
Attribution Modelling in Google Analytics and BeyondSECOND EDITION OUT NOW!
Attribution modelling is the process of determining the most effective marketing channels for investment. This book has been written to help you implement attribution modelling. It will teach you how to leverage the knowledge of attribution modelling in order to allocate marketing budget and understand buying behaviour.
Attribution Modelling in Google Ads and Facebook
This book has been written to help you implement attribution modelling in Google Ads (Google AdWords) and Facebook. It will teach you, how to leverage the knowledge of attribution modelling in order to understand the customer purchasing journey and determine the most effective marketing channels for investment.