Knowledgebase

How to add a Facebook pixel without a plugin  Print this Article

What is a Facebook pixel, and why do you need one? Essentially the Facebook pixel allows Facebook analytics to track your site and to make more effective your Facebook ad campaigns. It is a fairly straightforward process. There are plugins that accomplish this, but they are certainly not necessary. Just follow these simple steps!

  1. The first step is to create the pixel through Facebook. You will need to log into Facebook, and then go to Facebook Events Manager, and find the :"Pixels" tab. This will open a pop up with a button that says "Create a Pixel", simply click on that button:
  2. After the pixel has been made you will see a few options for how to install said pixel. Select the "Manually install the code yourself" option. Copy the code:

    then
  3. The last part is to add the code directly to the header.php file. It needs to be an unbroken section portion, which is easiest if added to the end of the <head> section. It must fall between the <head> and </head> tags, and be between its own tags:

Was this answer helpful?

Related Articles

How to Block Access to wp-login.php
 How To Block Access to wp-login.php   Skip to end of metadata   Page restrictions...
How to Make a WordPress Staging Area Using Plesk
This post was written to help our customers (and others) who are looking to easily make a staging...