Facebook Pixel is a cookie which enables you to track users’ behaviour on your website. It’s an essential tool to run efficient Facebook ads. With the Facebook pixel, you can create a custom audience, targeting either all the visitors of your website or a specific segment (for instance users who visited the checkout page but didn’t complete a purchase = abandoned cart).
If you have a dedicated success page at the end of a process (purchase, lead collection,…), you will also be able to track conversions using the Facebook Pixel (which will fire on the success page).
Here’s how to create your first Facebook Pixel via Business Manager (see my other article which explains how to create an advertising account in Business Manager).
First find PIXELS in the Measure & Report section.
Under Data Source, select Facebook pixel
Then name your pixel
If you don’t use any specific tag manager, select Manually install the code yourself (it’s very easy).
Then simply copy the code which you will paste in the HEAD section of your site. Very easy to do for instance via the THEME SETTINGS or THEME OPTIONS of most premium WordPress themes.
Example for DIVI (under THEME OPTIONS / INTEGRATION).
On the next screen you’ll have the option to create custom events for your Facebook pixel, e.g. PURCHASE, LEAD,…
You can always do it at a later stage. But here’s the procedure if you already know where to locate your success pages (the page a user will see after a successful purchase, after completing a form, etc.)
Activate the event type you want to track and paste the corresponding code in the BODY (after the HEAD section) of the success page. Example for LEAD.
You will need access at page level to add this code snippet. There are multiple plugins which allow you to do this. Here’s one of them: Tracking Code Manager (which you can also use to insert the main pixel code in the HEAD section of the whole site). You will find the plugin in WordPress repository.
Here’s the setup to add an event tracking code in the body section:
You’ll be able to select an active page under include posts “page”.
Always test your configuration after 24h to see whether you get some activity on the main pixel and on specific events if you’ve added some of them to your configuration.