How To Install The Facebook Pixel On Your Website

how to install Facebook pixel on your website Digital Training Institute

Facebook has created a new pixel and marketers need to add this new piece of code onto their website. In this blog post I will tell you how to install it on your website. If you have a WordPress website, well, there’s a plugin for it!


What is a Facebook pixel?

The Facebook pixel allows you to place a single pixel (or piece of code) on your entire website to report conversions, help you build audiences and get rich data insights about how people interact with your website. Why? Because as marketers we need to build our community and quantify growth across all platforms.


Why a new Facebook pixel?

Facebook recently introduced the Facebook Pixel to streamline targeted marketing activity.  Here’s what they say on their Facebook Help page.

The Facebook pixel combines the power of the conversion pixel and the Custom Audience pixel into a single pixel. You can now use the Facebook pixel to measure, optimize and build audiences for your ad campaigns, and no longer need to implement the conversion pixel and Custom Audience pixel. – Facebook

Facebook Pixel Table


Expert Tip!

Keep in mind you can only create one Facebook pixel per ad account. If you already have one, you won’t see the Create Pixel button.


Benefits of using the Facebook pixel

With the Facebook pixel, you’ll also be able to:

  • See rich insights: In Ads Manager you’ll see a dashboard which gives you information on the traffic across your website.
  • Share your pixel: Useful when working with an agency or Facebook Marketing Partner. Instead of implementing a second pixel for your agency, you can share your existing pixel with them through Business Manager.


Creating your pixel

Creating a pixel for your Facebook ad campaigns is quite straightforward. To do this, you will need to following the instructions below.

  • Go to your Facebook Pixel tab in Ads Manager.
  • Click ‘Create a Pixel’
  • Enter a name for your pixel. There’s only one pixel per ad account, so choose a name that represents your business. I’ve named mine Digital Training Institute.
  • Make sure you’ve checked the box to accept the terms
  • Click ‘Create Pixel’.

Installing the pixel into your website requires access to your website’s code as well as some basic coding knowledge. If you are not able to do this yourself, ask your web manager. It will require about 30 minutes of work and you will need to give your web manager admin access to your site along with the pixel embed code.


Installing the pixel into your website

  • Go to your Facebook Pixel tab in Ads Manager.
  • Click the Actions tab > View Pixel Code.
  • Click the code to highlight it.
  • Right-click and select Copy or use Ctrl+C/Cmd+C.
  • Click Done.
  • Go to your website’s HTML and paste the code between the <head></head> tags.


The pixel code

The Facebook pixel code is made up of two main elements: the base code and the standard event code. The base code should be placed on every page of your website.

What the new code looks like on an add-to-cart page.


Standard events

The one part of the code you’ll have to customize is the standard event section. There are 9 available standard events to choose from, such as “Add to cart” or “View Content”. These represent the different types of actions people take on your website and only need to be placed on some pages.


Standard events outside your pixel’s base code

You can also place a standard event outside of your pixel’s base code. To do so, add <script> tags to either side of the standard event so your website will recognize it as code. For example, here’s how you put a View Content event outside of the base code:

Customise your Facebook pixel code with standard events


If you want even more details, this article from Facebook explains the implementation process more comprehensively.

Tagged under:

1 Comment

  • Michele Reply

    The new Facebook pixel is really a must have to track custom audiences, create better retargeting campaigns and improve Facebook Ad conversions! I’m part of the LeadsBridge team and I’d like to share with you our new tool we developed to simplify all the process: the Pixel Enhancer. It’s free and it allows you to automatically fire Facebook standard events with a simple line of code, you can try it out here:

Leave a Reply

fifteen + four =

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.