Facebook Ads is a great marketing tool for your business. You can show your ads to the right audience and let them know about your offerings, to get more leads and increase your sales.
If you’re using Facebook ads to market your business, you need to Setup Facebook pixel on word press, to be able to optimize your ad campaigns and bring the most results.
But if you don’t have coding knowledge, it might be challenging to Setup Facebook pixel on WordPress website.
In fact, it’s very easy to do, all you need to do is insert a snippet of code to your website and you will be able to:
- Track your Facebook ads conversions.
- Re-target your website visitors (show ads to people who visited your website previously).
We will cover everything about Facebook Pixel and the best methods to add Facebook pixel to WordPress.
Finally, to check if everything is working out, you’ll learn how to test whether Facebook Pixel is working on your site
What Is Facebook Pixel?
Facebook Pixel is an analytics tool from Facebook, It’s not a general analytics tool like Google Analytics. Instead, Facebook Pixel specifically helps you measure, target, and enhance your Facebook ad campaigns.
Facebook created the Facebook Pixel to provide deeper insights to marketers, which enables them to measure the effectiveness of their marketing efforts and understand how Facebook users interact on the website.
Do You Need Facebook Pixel On Your WordPress Site?)
After adding a single script to your WordPress site, Facebook Pixel can help you:
- Create targeted audiences for Facebook ads (custom audiences) – to reach the right audience and find new leads and customers on Facebook and Instagram. including the ability to “re-target” people who’ve been on your website from Facebook.
- Expand Your Audience – find new customers by creating a Lookalike Audience that matches the behaviors of your website visitors to the closest 1% of Facebook users in a geographic area.
- Trigger Actions You Care About – Optimize ads for conversions, landing page views or any other action that matters to your business, and Optimize your ad campaign spend, like setting up automatic bidding to target the people who are most likely to make a purchase at your site.
- More Data – Get a deep understanding of your Facebook Community and how they’re interacting with your website and track the conversion rate from your Facebook ad campaigns, like how many people make a purchase after clicking a Facebook ad.
Now that you know what is Facebook Pixel and how it can benefit your business, let’s talk about how to install it on your WordPress website.
How to Setup Facebook Pixel on WordPress Website?
Installing Facebook Pixel is a very easy process, which is done by adding a little snippet of code to your website.
Step 1: Create Facebook Pixel from Facebook Ads Manager
First, you need to create a Facebook Pixel.
If you haven’t already created a Pixel, you can create only one pixel from your Facebook ads account, which can be used on all your website.
- Go to your Facebook Ads Manager and select the ‘Pixels’ tab.
Navigate to the Pixels tab in your Facebook Ads Manager.
=> go there by clicking this link.
- Click on the green button ‘Create a Pixel’.
A box should appear that asks for a name, fill in the name of the pixel and then press ‘Create’.
Step 2: Get Facebook Pixel Tracking Code (for manual method only)
your Facebook Pixel, you will see Install Your Pixel Code box
(if you don’t, => go to the Pixel tab and click Set up Pixel).
From these options, choose “Manually Install the Code Yourself”.
Then scroll down to the Facebook Pixel tracking code section and copy it:
Keep this code, because you’re going to need it in the next step.
Step 3: Add Facebook Pixel to WordPress
There are 2 ways to add Facebook pixel to your WordPress website:
- Manual code – this is an easy basic method to add the Facebook Pixel code.
(If you just want to use Facebook Pixel to create Lookalike audiences and other more basic features, the manual code implementation is the simplest solution for your needs.)
- Using a free a plugin – if you use this method you will be able to create custom audiences and conversion goals inside your WordPress dashboard.
(If you want to use custom audiences and conversion goals, then you will need to follow the plugin method.)
Method 1: add Facebook Pixel to WordPress Manually
Next, you need to add the generated tracking code right above the closing </head>tag on your WordPress website.
There are 2 ways to do this: (choose only 1)
- Add it directly to the header.php file in your child theme.
Go to Appearance → Editor and find your header.php file then paste the Facebook Pixel script right before the </head> tag:
· Add Facebook Pixel tracking code to WordPress <head> section using a free (and lightweight) plugin
While there are many different ways that you can add code snippets like this to your WordPress website, I think the easiest method is using a free plugin called Insert Headers and Footers:
- Install and activate the free Insert Headers and Footers plugin.
=> Install Insert Headers and Footers plugin from here.
- Go to Settings → Insert Headers and Footers.
- Paste the Facebook Pixel tracking code into Scripts in Header box.
- Click Save.
Wonderful! You just learned how to add Facebook Pixel to WordPress.
I’ll show you how to test if your new Facebook Pixel is working or not at the end of this article. But first, let me cover the plugin method very quickly.
Method 2: Add Facebook Pixel to WordPress Using A Free Plugin
The benefits of using Pixel Caffeine Plugin are that you can:
- Create custom audience right from your WordPress dashboard.
The custom audience functionality is very helpful for more advanced Facebook advertisers.
- Create Facebook Dynamic Ads for Woo-commerce.
- Easily track conversions.
Before you use the plugin, you need to create a Facebook Pixel in the Facebook Ads Manager (you can follow the instructions in Step 1).
How to setup Facebook Pixel on WordPress with Pixel Caffeine Plugin
As an alternative to the manual method, you can also use the free Pixel Caffeine Plugin from AdEspresso (popular advertising tool from Hootsuite).
- install and activate the plugin:
=> Pixel Caffeine plugin from WordPress.org.
- Configure Pixel Caffeine.
- go to Pixel Caffeine → General Settings in your WordPress dashboard.
- Click the FACEBOOK CONNECT button (this is necessary if you want full functionality)
To add the Facebook Pixel tracking code, you’ll need to connect your Facebook account to Pixel Caffeine (giving Pixel Caffeine access also lets it help you create custom audiences later on).
- You will see a prompt saying that “Pixel Caffeine would like to manage your business”. Click OK.
- You will be taken back to your WordPress dashboard, where you can select your Ad account and Pixel ID.
Awesome! Your Facebook Pixel is now up and running.
To take advantage of Pixel Caffeine’s more advanced features, you can use the tabs for Custom Audiences and Conversions/Events.
Set Up Conversion Tracking (Optional)
If you want to track your own conversions – like when a user visits a certain page or clicks a link – you can do this from the Conversion/Events tab.
Create Custom Audiences (Optional)
To create a custom audience for ad targeting, you can use the Custom Audiences tab
How to Check If Facebook Pixel Is Working or not
After adding Facebook Pixel to WordPress, Make sure Facebook Pixel is working.
To make sure that your newly-added Facebook Pixel snippet is
working, you can use this Google Chrome Extension:
=> The official Facebook Pixel Helper browser extension for Chrome.
after installing this extension, navigate to your website where you added Facebook Pixel code and click on the extension’s icon.
If Facebook Pixel is active, you will see a success message, as well as more tracking information (like any conversion events).
And that’s all you need to do to add Facebook Pixel to WordPress.
If you advertise your business on Facebook, you need to Setup Facebook pixel on WordPress, to evaluate your results from Facebook Ads campaigns, and benefit from more advanced features like custom audiences and re-targeting.
To setup Facebook Pixel on WordPress website, you can either add the tracking code before the closing</head> tag manually or you can use Pixel Caffeine free plugin.
After adding the tracking code, make sure to check if it’s working properly with the free Facebook Pixel Helper extension.