How to create and Install Facebook Pixel: A Complete Guide

How to create and Install Facebook Pixel: A Complete Guide

If you are looking to understand what Facebook pixel is, what it does and how to set it up, then you are at the right place.

In this Guide, I will cover everything about Facebook Pixel.

So Let’s start.

What is Facebook Pixel?

Facebook Pixel is a small piece of a JavaScript code.

It helps Facebook in Tracking data like:

A) Number of People who visited your website.

B) Pages they visited.

C) The time they spent on the Website.

D) Other actions they took on the website ( Like Viewing product, Adding the product to cart, Check Out, Purchase etc.)

E) Tracking conversions

You can use this information to optimize your campaigns as well as to run retargeting ads.

Types of Facebook Pixel

A Facebook pixel can be divided into 2 types.

1) Standard Pixel

2) Event-Based Pixel

Standard pixel: Standard Pixel tracks all the pages of your website.

This Pixel is placed in the header of the website.

It should fire on all the pages of the website.

Event-Based Pixel: It tracks specific events on your website. For Example: Leads, sales, Add to cart, View Content etc.

This should fire on specific pages of the website. Basically the pages you consider as conversion.

If your Goal is to generate Leads, then You can fire Lead event Pixel or complete Registration Pixel on the Thank You page of your website.

How to Create Facebook Pixel:

Here is the Step by Step Instruction for Creating the FB Pixel on your WordPress website:

Step 1 Go to Your ad manager and click the three lines you see in the top extreme right section of the page.

 

Step 2 Once you Click a new section would appear with multiple options, Now Click Pixel.

 

 

Step 3: Now You will See a Green Button which says “Create a Pixel”. Click this button.

 

Step 4: Name your Pixel and Click Create.

 

 

Congratulations you just successfully created your Facebook Pixel.

How to Install Facebook Pixel:

You just created your Pixel, Now you need to install it on Your website.

Once you create your pixel you will see a screen which will look something like Below.

It lists 3 methods to install Facebook Pixel.

1) Using Google Tag Manager

2) Manual Installation

3) Emailing instructions to a developer

If you have a WordPress Website you can install Facebook Pixel by

1) Directly placing the code in the Editor section of your website

or

2)Using WordPress Plugin

or

3) Install the code using Google Tag Manager.

You don’t need to use all these 3 methods together to do the pixel installation. You can use either of these 3.

However Google Tag Manager is the Best method, I recommend Google tag Manager to you.

Let’s Learn Each of these 3 Methods:

Method No 1: Directly placing the code in the Editor section of your website

Step 1: Go To your ad account again and go to Pixels.

 

Step 2: You will see a ” VIEW SET UP INSTRUCTIONS” button.

 

Step 3: Click it and you will see something like below.

 

 

Step 4: Click Manually Install the code yourself.

Step 5: Scroll Down to ” Copy the entire pixel code and paste it into the website header“\

 

Step 6: Copy the code

Step 7: Go to your WordPress Dashboard then Appearance then Editor.

 

Step 8: Click editor. Now You will edit theme section.

 

Step 9: In the Right-hand side, you will find a header.php file. Click it.

Step 10: Here you will find a head code. It will be written like this: <head>.

Step 11: Paste the code you copied earlier just after this <head> thing and then Update FIle.

Bingo, You just completed the Installation of Facebook Pixel using Method Number 1.

Now let’s move to Method No. 2.

Method No 2: Using WordPress Plugin

To install the code using a WordPress Plugin you can use a Plugin called “Tracking Code Manager”.

( I am sure there are various other plugins as well to do the same thing, however, I find this the best).

Here is the Step by Step Instructions:

Step 1: Go to your WordPress, then Plugins and then Add New.

Step 2: Search Tracking code Manager and Install and Activate the First Plugin.

 

Step 3: Once you install this plugin you can find it in the settings section of the WordPress Dashboard.

 

 

Step 4: Click it and you will see something like the Below screen. Just click ” CLICK HERE” to create your tag.

 

Step 5: Name Your tag and paste the Facebook Tracking code we copied earlier in “Paste your Tracking Code here” section. You need to place this in the big Black screen.

Step 6: Keep Rest of the setting like the Below screen and Click Save.

 

 

Bingo.. 🙂 Congratulations you just installed the Facebook Pixel using the Method No. 2.

Now Let’s talk about Method No 3

Method No 3: Using Google Tag Manager

Before we start using Google Tag Manager to Install Facebook Pixel, we need to make sure that Google Tag Manager is installed on our Website.

Here are the Steps to Install Google Tag Manager on Your Website:

Step 1: To start using Google tag manager, go to https://www.google.com/analytics/tag-manager/ and Create your account.

Step 2: Once done, You need to Go to Your WordPress Dashboard and install “DuracellTomi’s Google Tag Manager for WordPress” plugin.

Step 3: Once Installed you can find this Plugin in the Settings section. Click ” Google tag manager” inside Settings section and you will be greeted with a screen like the one below.

 

Step 4: Go to your Google Tag manager account and copy your tag Manager ID. It starts with GTM.

 

 

Step 5: Paste this code into Google tag manager ID Section of the Plugin we just installed. “DuracellTomi’s Google Tag Manager for WordPress”

Congratulations you just Installed Google Tag Manager on your website.

Now you can install Facebook Pixel using Google Tag Manager.

Here are the Detailed Steps:

Step 1: Go to Google tag manager and Click on your website.

 

 

Step 2: Click Add a New Tag. Name your tag.

Step 3: Click ” Tag ” and select Custom HTML.

Step 4: Paste Facebook Pixel code inside the Box.

Step 5: Click triggering and Select Page View and then All Page Views. Click SAVE.

Step 6: Now Click Submit and then Publish and then Click SKIP.

Congratulations you just installed the Standard Facebook Pixel using Google Tag Manager.

The pixel that we just installed will track standard page views.

Now if we want to track specific events Like Leads, Sign up then we have to install the EVENTS pixel on our website.

As Google Tag Manager is the best way to manage tags on our website, we will learn how to implement Event Pixel using Google tag manager.

Let’s start.

Here are the Detailed Steps:

Step 1: Go To your ad account again and go to Pixels.

Step 2: You will see a ” VIEW SET UP INSTRUCTIONS” button.

Step 3: Click Manually Install the code yourself.

Step 4: Now you will see the Standard Pixel code, we have already installed this, so hit Continue.

Step 5: If you want to track Leads, click Leads.

 

Step 6: Copy the code.

Step 7: Go to Google Tag Manager and Click Add a New tag.

Step 8: Name your tag and select Custom HTML in the tag section.

Step 9: Paste your code here.

Step 10. Click Trigger and then click + sign on an extreme right section.

Now Name Your trigger and Select Some Page Views. [We need to fire this Pixel on a Specific Page( Our Thank You page]

Step 10: Make sure you select the below settings.

 

Step 11: Paste the URL you consider as conversion in the Blank section.

Step 12: Click SAVE. Now Click Submit and then Publish and then Click SKIP.

Congratulations, you Just Installed Facebook Event Pixel on your website.

We just installed the Facebook Lead event Pixel on your website, You can similarly install other event pixels on your website.

Above installations will work perfectly if you are running a consulting/service business however if you are running an e-commerce store on WordPress you need fire specific events like View Content, Add to Cart, Initiate Check Out, Order Confirmation events on your website.

To Fire these different E-commerce events you can either use Google Tag Manager or a WordPress Plugin Called Pixel Caffeine.

Once Installed You need to go Pixel Caffeine the General Settings and connect your Website to your Facebook Ad Account.

 

 

Once done just scroll and enable the e-commerce tracking.

 

You are all good now.

Now, Facebook will start tracking all the e-commerce events.

I look forward to hearing your thoughts on this Post. 🙂

Close Menu