If you own a digital agency or are a social media professional who creates content for your clients, this is for you. Marketing today is…
In the last two weeks, we've covered how you can create custom events on Facebook pixels that allow you to track, optimize, and visit visits based on time spent on a page and scrolling depth. Today, we will take this step further and combine the two.
The reason for this is simple. While both the time on a page and the depth of scrolling are good indicators in themselves of the quality of visits, everyone has a weakness. You can spend three minutes looking at the title without scrolling (or simply load the page and walk away). You can scroll through a post in 10 seconds and spend no time reading it.
Several people have asked me if the two can be combined and I have good news: I can!
Today, we will isolate that extremely valuable audience of people who scroll through at least 70% of a blog post AND spend at least two minutes reading it. If you read any of the messages in the last two weeks, portions of this post will be repetitive. But I want to make sure that if you missed those posts, you know how to set up the base pixel in Google Tag Manager and test the events.
I will go through even more details in my next Facebook Pixel masterclass (the first lesson is free). Go here to sign up!
Add the basic Facebook pixel
I guess you have the base Facebook pixel code already installed on your site. Anyway, let's get through this.
We do this inside Google Tag Manager. Although there are likely ways to do this elsewhere, the variables and triggers provided by GTM facilitate execution.
1. Create a label and name it "Facebook – Basic Pixel".
2. Choose "Custom HTML" as the tag type under Tag Setup.
3. Paste the base pixel code in its entirety into the HTML text box. Below is an example, but you should use your own unique code for your ad account.
4. Under Trigger, we want to run our basic pixel code on all pages of our website.
There are some variables that we have created in the last two weeks that we will use here. If you haven't created them yet, let's do it now. We need a pixel to record the percentage depth and scrolling time on a page, so we can add variables to Google Tag Manager.
1. Create a variable named "DLV – gtm.timerEventNumber" using the data level variable type. Use the variable name of the data layer "gtm.timerEventNumber."
2. Create a variable called "DLV – gtm.scrollThreshold" using the data level variable type. Use the variable name of the data layer "gtm.scrollThreshold".
Create a trigger
We want Facebook to trigger an event when a visitor spends at least 120 seconds and travels at least 70% of the way through a blog post.
1. Create a new trigger in Google Tag Manager and name it "Blog Posting – 120+ Seconds and 70% Scrolling."
2. Select the "Custom Event" trigger type.
3. Enter "^ gtm . (Timer | scrollDepth) $ ”for the event name and check the box to use Regex Matching.
4. Select to trigger the "Certain custom events" trigger.
5. Turn on the shutter when DLV – gtm.timerEventNumber is greater than or equal to 4. Because we use 30 second intervals, this is 120 seconds.
6. Turn on the shutter when DLV – gtm.scrollThreshold is greater than or equal to 70.
Create a label
Now, we'll create a new tag in Google Tag Manager that will refer to the trigger and the variables we just made.
1. Create a new tag and name it "Facebook – Blog – 120+ seconds And 70% scroll." Of course, your name belongs to you.
2. Use the custom HTML tag type.
3. Paste the following code into the HTML text box …
It should look like this …
4. In Advanced Settings> Tag Sequencing, check the box next to "Facebook – Blog – 120+ seconds AND 70% Fire Scroll".
5. Select the "Facebook – Basic Pixel" tab under configuration.
6. Under Trigger, select the trigger you created earlier.
Test your event
Let's make sure this event works. In your Event Manager, select your pixel and click Test Event on the left.
Open a separate window or tab and go to a page on your website where this event should start. Go through the whole page and it should appear in this window.
You can also use Facebook Pixel Helper to test in the same way.
Create custom conversions
We have created a custom conversion for this event. We need this for tracking and optimization.
1. Instead of "All URL traffic", select "Blog tracking" in Custom events.
2. Click to add a rule.
3. Instead of "URL", select "Event parameters".
4. Select "Time and depth" as the custom setting.
5. Enter "120" next to "Contains". We created only one custom parameter in this event, so this rule should be selected.
6. Name it, select a category (probably "Other") and set a value (probably leave it blank).
You can test these custom conversions just as you tested your event. You should also start seeing activity in your custom conversion list. Note that the activity will be smaller than the one you see with the time on the page and only with the depth of scrolling. These are now the best of the best visits!
Add columns to your ads
This is the information you should monitor in your advertising reports, especially when driving traffic to blog posts. To do this, click Customize Columns …
Then find your new custom conversion and check the boxes to add it to your report.
Optimize for high quality traffic
If you normally run campaigns to promote your blog posts, let's do it a little differently.
First, use the Conversions goal, not Traffic.
When you set Ad Delivery Optimization to your ad set, select the custom conversion that you created.
By setting up campaigns in this way, Facebook will try to show your ads the best chance of spending at least two minutes and will run at least 70% on a blog post.
Create custom audiences for websites
Now we can create audiences based on the new event we created …
This allows you to focus on targeting those who READ your blog post – beyond these quick scanners and headlines.
Facebook Pixel Masterclass
I will go into detail on this topic (and many more) in my future Facebook Pixel Masterclass. We will talk about everything from the basics to the most advanced. I hope you will join!
This approach changed my advertising on Facebook. It gives me a much clearer view of the quality of the visitor I lead and allows me to optimize for that type of visitor. This isolated audience also gives me an option to target a small, valuable group.
Are you doing something similar? What do you think?
Let me know in the comments below!