Ahh!!
The Facebook Pixel, a little code that you need to install onto your website
in order to make Facebook Tracking work and if you have Google Tag Manager
installed, it's quite easy to do.
Let me show you on my computer.
But before we dive in, I actually need to mention that this is a lesson of our newly
updated Facebook Pixel Tracking Course
which you can find inside of our Measure Masters Membership.
Now inside of Measure Masters we have tons of more courses on Analytics and
Tracking Setup and we also have a great community where we help each other out
as a sparring partner, but you can also get personalized support from myself.
So if you're interested in checking out, Measure Masters head over to measure
school.com/measure masters, and you'll find all the information over there.
So with that out of the way, let me show you how to set up the Facebook
Pixel with Google Tag Manager.
In this first video we are going to set up Page View Tracking
with the Facebook Pixel.
So I have my entities open here already.
So we have Google Tag Manager, we have our demo shop where I have
Google Tag Manager installed on and we have our Events Manager open.
So that is something you would need to open up in your account.
It might look a little bit different from what you're seeing here.
We are recording this course in 2021.
So if there's anything that changed, which is very common for Facebook, don't
threat it, you will probably find the same buttons somewhere else at this point
so just be flexible here and try to figure out where you can find certain things.
I also have open here, the Facebook Pixel Documentation, where we'll be
able to look into what is actually requested for the Facebook Developer.
And we'll go through this so you have a little bit of a
reference where to look things up.
So for the first part, I want to put my Google Tag Manager
account into the preview mode.
I go over here to Preview, since I don't have a version published yet, it will
ask me to first publish an empty version.
So I'll be doing that.
Then we can go to Preview and connect our Google Tag Assistant to our account
and we now see that Google Tag Manager is connected to our tag assistant.
Nothing is firing because I don't have any tags of variables
or triggers in here just yet.
Well, there's a new container now with this new version, so let's
just click on update here and we'll go into this new version.
Okay.
Now we can start to set up our Facebook Pixel for that,
we'll go over to Tags here and click on new.
And then in this window, we'll just click on this big tag configuration button,
and then we'll have our templates that we can install into our Google Tag Manager.
Unfortunately, there is no official tag template from Facebook, but we
have the community gallery where we will find a Facebook Pixel template.
So just search for Facebook.
And the different ones out there.
We have the ones for the Facebook conversion API, the customer chat.
This one is the one that we will deploy for the Facebook Pixel it's
made by the Facebook Incubator taken over by the Facebook
Incubator, because it was actually originally built by Seymour Hover.
So we're going to click on that and then, simply add to workspace.
This will give us a little bit of a warning of what this
pixel will be able to do.
We'll accept this and click add.
Now this Facebook Pixel template is installed on our page, anytime
we go back to our list here, we should find our Facebook Pixel
under the Custom Tag Templates.
Okay.
Here you find all the configurations that we would need to make in
order to deploy our first pixel.
The first thing that we would need is our Facebook Pixel ID.
And this ID can be found inside our Events Manager, different
spaces, where this would be set up.
We can find it here pretty conveniently by just clicking on it.
It will be copied to the clipboard.
There's another way to access it.
You could go to add events here and then from pixel, and then here we
have installed events using code that will open up the conversion tracking.
Now, we want to just open up now.
So, this is the way to get your Facebook Pixel.
We can go over to Google Tag Manager and put it here into the ID.
Now I would recommend to actually save this in a variable.
If you don't know what a variable is, it's a placeholder that we can reuse
so we can go to this brick icon here, and we can save our variable in a,
or we can save our pixel ID in a new variable by clicking on this plus button.
And this will be a constant variable
for our Facebook Pixel ID.
And I'm also going to put the ID in here so I always know what idea
is if I have multiple of those.
So I'm going to go on variable configuration.
We'll choose the constant type of variable here, and then
we simply put our ID in here.
So that will now be in a variable, you need to get rid of this,
mark by these two curly brackets at the beginning and the end.
Oops.
Right here.
So anytime you create a new Facebook Pixel or new tag, inside of Google Tag Manager,
you don't have to remember that number.
You can just go over to your variables and here you have your Facebook Pixel ID.
So this is now installed.
And then we go over to the event configuration.
Now there are different events as we will learn in the next lesson.
We just want to go with the standard Page View Event so you don't really
have to change anything here.
There are some more settings that you might need to choose if
you want to work with consent.
But that's something that is specific to Google Tag Manager
and your website, and obviously to the country that you operate in,
so we'll leave that out for now.
We'll go into the other configurations later on.
All we need to choose now is the trigger.
And since it's a Page View Tag, we simply need to deploy this on all
pages and this is pre-configured, so we'll go here with all pages and
then we need to give this all a name.
And I usually have the naming convention to use the tool,
so in our case, Facebook, and then we are deploying an event, which is the
Page View Event that should do it.
Let's save this and then go into the Preview mode.
Ok we already were in the Preview mode, but we always need to
click on it after you changed something so it actually updates.
And now we see on our page, we have
fired our Facebook Page View Event.
So that seems to work and it's now deploying our Facebook Pixel ID on
the container loaded event right here.
So Facebook Pixel Page View here we go.
We have our ID.
It's sending out the Page View name and we don't have any problems here.
It says fired.
So in the Preview mode, this seems to work.
This is not a deployed on our website.
Now how can you debug and make actually sure that it's actually deployed?
Well, the next line of defense here is the actual Pixel Helper, there's
a extension that you can install the Facebook Pixel Helper and here you find
information about your Facebook Pixel, something went wrong, something was not
deployed correctly or something stubble.
You would find it in here.
Now the only thing that we need to pay attention to is this Page View because
this is actually what we deploy and we can open this up and we see all the
information that has been sent over.
So for example, this URL was called our, URL that we are currently
on has been transferred over.
We also have the location here.
So, this is the URL that we see in this callback URL.
And this gives us a little bit of information about what has
fired and we get this green check mark, which also means, okay, the
Page View has fired correctly.
Now you might see Micro Automatically Detected the data, Micro Data,
so Facebook, the Facebook Pixel has the functionality to actually go onto
the page, scan it and find any kind of special information that is maybe on
the page itself, for example, Schema.org data, data layer data, and so on.
But, uh, here, apparently it didn't find anything.
Here we find a little bit of Schema data, although it didn't show anything up here.
Now this is data that you can't really control in a sense
because Facebook pulls it automatically out of your page.
So this is not something we can manipulate, but it's something
that Facebook tracks automatically.
And this is potentially data that they later on surface
inside of the Events Manager.
Now, inside of this Facebook Pixel Helper it shows us now,
okay, we fired this correctly.
So everything should be working.
Well, the ultimate test is always to look into your tool that you are
sending data to so in our case, we would go over to the Events Manager
and there's a tab called Test Events.
Now for that, you actually need to put your browser in a certain state.
And for that, you need to put in the URL here that you are actually testing.
So in our case would just go over here and put the URL in here, this will
set a cookie and it will know when to send that data over to Facebook.
Now, unfortunately we see here that this tab is not connected to the Tag Assistant
so there is no Facebook Pixel being deployed and nothing could be tracked.
But since this cookie is now set on our browser, we can just close this,
go back to our tab that is actually connected and let's press reload here.
That should also deploy our Facebook Pixel and here its also being deployed
Page View And then in the Events Manager we see now the information
that has been sent over, we got this Page View Event and the browser and
the information that was sent over.
So this seems to be working correctly.
Now we just need to deploy it on all the browsers, all the users who are coming
live to our website, we haven't done this yet because this is just inside of
the Preview mode inside of our tab here.
If you go onto this page with another browser, it would not work,
and therefore we need to submit a version first live to our website.
So I'm going to go here into Submit you give a version name,
you can put more description in here if you want and keep a documentation
and then we click Publish.
And now this should be live on our website.
So what we can do is we can go out of the Tag Assitant so not be connected anymore.
Reload our page right here we don't need the GTM debug.
So we just normally on the page, now we should see that the
Facebook Pixel is being deployed.
And if this is not the case, then you might need to reload your page or do
a hard refresh, which is Command Shift R or, um, Control Shift R which gets
rid of the cache of your browser.
And then you should be able hopefully to see your Page View being even deployed if
we have the preview mode not connected.
So we have now deployed Page View Tracking correctly for our
Facebook Pixel and this might be already enough for your use cases.
So with that in place, you can create Custom Audiences, you can create Custom
Conversions and generally do a lot of tracking already, just based on this Page
View Pixel that we have now deployed.
I don't want to get too deep into the specifics of how these now
could be used because we are more here on the measurement side of
sending data into our system.
How it's correctly used, but it's definitely very powerful already
just to have this one event, the Page View being deployed through
the Facebook Pixel to your page.
But if you want to do more with the Facebook Pixel, we'll talk about
this in the next lesson where we are going to set up Custom Events
with our Facebook Pixel Okay.
As mentioned, this was a lesson from our new Facebook Pixel Tracking course, which
you can find inside of Measure Masters and if you want to dive deeper, Into how
to set up Custom Events, for example, attached Dynamic Data to your Events to
send over and make Dynamic Ads work for you or all the other settings that you
find inside of the Facebook Pixel template
then head over to measure school.com/measure masters, check out
the membership, and then you can dive into this course inside of the membership
we obviously have much more around Tracking and Analytics so check it out at
measure school.com/measure masters, and that's already it for this week's video.
Thank you for watching.
My name is Julian till the next time.