Apa itu facebook tracking code

You might have been using Facebook ads for a while. You’ve probably had some clicks, some shares, maybe even some sales.

But are you tracking whether your ads are resulting in a positive return on investment? Ie, are you making a profit?

In this article, I’m going to show you how to add your Facebook Pixel to ClickFunnels; literally taking the blindfold off, and putting you right in the driver’s seat. I’ll show you how to set up conversion tracking, and I’ll demonstrate how to use it to help build your Facebook ad campaigns.

I mean: driving with your eyes covered is just crazy. Who would do that?

(Ps. although I’m using ClickFunnels as an example here, this applies regardless of what tool you use)

Why Do We Need To Set Up Funnels and Facebook Conversion Tracking?

We want to be able to see where our advertising spend is going. 

Are you seeing results? Do you have a precise analysis of how much every converting engagement is costing you?

Without conversion tracking, you’re not really in control of your advertising campaign. 

Thankfully, it’s super easy to do.

Step One: Building Your Funnel

You need a funnel before you can effectively track your campaigns. 

If you’re not sure how to go about setting up your funnel, Gavin Bell is here to help. 

We will give you the low-down on sales funnels, as well as guidance on creating effective sales-driven content and a logical sequence to maximise your conversion rate. 

Once you have your funnel set up, you can move on to Step Two. 

Step Two: Get Your Facebook Pixel

The Facebook Pixel is a piece of code that helps you:

  • Track performance – so we can see whether people are buying, etc.
  • Re-target people – who didn’t complete a transaction the first time round.
  • Allows Facebook to get smarter, optimising future campaigns for you. 

To get and install your Facebook Pixel, you need to:

  • Go to the Business Manager Page, and click on the hamburger menu
  • Go to All Tools
  • Click on Pixels.

When you come to Pixels, you’ll come to a page like this:

Apa itu facebook tracking code

If you don’t have a Pixel yet, it’s simple to set up. If you haven’t set one up yet, just follow the steps. 

  • Click on Set Up
  • Click on Install Pixel.

This gives you three options. 

  1. Add Pixel using partner integration – for use if you’re using a service such as Google Tag Manager
  2. Manually add Pixel code to website – the method I’m going to show you today
  3. Email instructions to a web developer – if a third-party developer is setting up the Facebook Pixel for you. 

Click on Manually add Pixel code to website.

A pop-up window appears that contains the code that makes up the Facebook Pixel. Highlight the text and copy it.

Apa itu facebook tracking code

There’s a second section that asks whether you want Automatic Advanced Matching

You do.  

Make sure it’s set to On. This allows the Pixel to gather additional data to help optimise your campaign. 

Simple so far: just copy the code from the pop-up window. 

Step Three: Copy The Pixel Code To Your Funnel

For this demo, I’m using ClickFunnels but the process is the same regardless of the software you’re using. The layout might be slightly different, but the process will be the same. 

Firstly, you need to make sure that your funnel contains at least two stages – otherwise, the Pixel can’t identify a conversion.

Say, for example, you’re offering a free download. 

Your landing page might contain your sales copy with a sign-up page where you might collect user details. 

That then leads to a confirmation/thank you page.

And that page is key – as when someone lands on that thank you page, Facebook knows they’ve converted. 

Saying that, we want to ensure the Facebook Pixel is installed across all pages in our funnel.

Setting Up The Conversion Tracking On ClickFunnels

Choose the page in your funnel that you want to track (your Thank You page). 

Click on Edit Page. This will take you to your Thank You page editor. Click on Settings> Tracking Code

A new window will pop up:

Apa itu facebook tracking code

This is where you paste the Pixel code.

Simple.

Step Four: Manually Adjust The Code To Show Facebook That You’ve Set Up The Conversion Tracking

Within ClickFunnels, you have two options: Custom Conversions or Standard Events. 

Custom Conversions are where we tell Facebook ads which URL to identify as our conversion. Perhaps it might be mrgavinbell.co.uk/thank-you

So, when somebody clicks from your Facebook ad and hits your funnel, it doesn’t get classed as a conversion until the user finally hits your assigned URL. 

Standard Events are where we edit the Facebook Pixel code. Don’t panic. It’s MUCH more straightforward than it sounds and you don’t need any coding knowledge. 

When it comes to ClickFunnels, we want to use Standard Events; Custom Conversions doesn’t seem to work very well (don’t ask me why).

With Standard Events, rather than defining the URL, we edit the code slightly.

In this context, the triggering of the Thank You page is the “Event”. ClickFunnels reports the Event (of sending the Thank You page) to Facebook, and Facebook translates that Event as our conversion.

How To Add A Standard Event To Your Facebook Pixel

In the Pixel code we’ve just added to the Thank You page editor, you’ll find a line:

fbq (‘track’, ‘PageView’)

Copy that line, and paste it underneath. 

Replace the word “PageView” with something you’ll remember such as “FreeGuideDownload”. It doesn’t actually matter what you choose.

So, the two lines should be:

fbq (‘track’, ‘PageView’)

fbq (‘track’, ‘FreeGuideDownload’)

Hit the X to close down the editor window, and click Save

That’s it.

Step Five: Check Your Pixel Is Working

You’ll need a Chrome plug-in called Facebook Pixel Helper

In Chrome, go to the URL that your customer will use to trigger the conversion. Click on your Facebook Pixel Helper plug-in, and it will confirm whether the Pixel is installed. 

Cross-reference the ID for the Pixel with the ID in your Facebook Business Manager. 

The Pixel Helper will also confirm that the event “FreeGuideDownload” has loaded. 

All good so far. 

The next stage is to tell Facebook that you’re using the Standard Event (in this case “FreeGuideDownload”) to identify your conversion. 

This tells us how much it costs you to get a user to convert. 

Go back into the Facebook Pixel page, or choose Custom Conversions from the main menu in Facebook Business Manager. 

Click Create Custom Conversion

As default, the Custom Conversion pop-up is ready for Custom Conversions (as the name of the window suggests). Click the Website Event drop-down and choose the Standard Event you’ve just set up in ClickFunnels.

Apa itu facebook tracking code

N.B. Your Event might not have downloaded yet, so click the refresh button on your browser a few times to allow the Facebook Campaign Manager to complete the connection. 

Name the Event, select the Category (lead, purchase, etc.), and then click Create

Step Seven: Create Your Facebook Ad Campaign

Next, set up your campaign to drive traffic to your funnel. Once that’s ready to roll, follow these steps:

Go to the Campaign section and click Create Conversion

In the “What is your marketing objective?” box, choose Conversion

Give your campaign a title. Click Continue

You’ll find yourself at the Ad Set page

Go to Conversion Event and untick the default, and choose your conversion event (“FreeGuideDownload”) from the drop-down menu.

Your Event may have a green, red, or grey light. At this stage, you can just ignore this (it just indicates that you have or haven’t had any conversions yet).

Then, scroll down to the familiar targeting, placement and other campaign options, complete these as usual, then hit Publish

Start Tracking

Once this is set-up, you’ll be able to begin precisely tracking your campaign. 

It might seem like a lot of work at first, but once you’ve set up your funnel, this process becomes second nature. 

Consider the value of identifying more accurately how your campaigns are resonating with your audience. Learn what they react to and what they ignore. You’ll never waste your money on another Facebook ad campaign ever again. 

Without tracking, you’ll never know what works and what doesn’t. 

There’s More…

As you’ve probably realised by now, Facebook conversion tracking and marketing processes are constantly evolving: the algorithms develop over time, and we find new ways of getting more precise detail that can help to shape, navigate, and create our marketing campaigns. 

And I share them with you on The Yatter blog.

If you have questions, comments, or any ideas you’d like to share, please feel free to let us know, and we’ll happily respond. 

Thanks for reading.

Happy marketing, people.