If you’ve been investing in video content lately, and you should be, you’ll want to find the most ways to use that content. Publishing to your Facebook Page, both Facebook and Instagram Stories, posting on YouTube, and embedding that YouTube video on your website are all great ways to reuse content. By now, you also know that we’re big advocates of making data-based marketing decisions. We love gathering data and using that to guide our strategies. YouTube gives you analytics but did you know that with Google Tag Manager you can track just how people are interacting with the embedded videos on your site?

Google Tag Manager has just released the YouTube Video trigger, which gives you native support for YouTube video tracking. And it’s great! It includes just about everything you’d want to track:

  • Video starts
  • Video completions
  • Pausing the video
  • What percentage of the video was watched

How to Track YouTube Video Embeds

First, you’ll want to already have Google Tag Manager set up on your site. Then you’re going to set up some new variables and create some new tags and triggers. Let’s start with variables…

Set up Video Variables

  1. In GTM, navigate to the Variables section.
  2. The top part of the Variables section is for Built-In Variables. In this section click the Configure button.
  3. In the menu that opens; scroll down and check:
    1. Video Status
    2. Video Title
    3. Video Percent
  4. Next you’ll want to create a user-defined variable to make the Video Status results a bit more user-friendly
  5. In the User-Defined Variables section, click on the New button
  6. Name the variable Video Status Lookup
  7. For the variable type, scroll down to the Utilities section and select Lookup Table
  8. For the Input Variable, select {{Video Status}} from the dropdown
  9. Next, add these four rows:
    1. Start | Played
    2. Pause | Paused
    3. Progress | Watched – {{Video Percent}}%
    4. Complete | Finished
  10. Save the variable.

Create the Tag and Trigger

  1. Click on Tags in the left-hand menu and then click on the New button.
  2. Select Universal Analytics as your tag type
  3. For track type, choose Event
  4. Category: YouTube Engagement
    Action: {{Video Status Lookup}}
    Label: {{Video Title}}
  5. Under Google Analytics settings, choose your existing GA settings variable or manually override to enter your GA tracking number.
  6. In the Triggering box, click to choose a trigger and then click on the plus icon in upper right corner to set up a new trigger.
  7. Name the new trigger YouTube Video Trigger and click in the Configuration box to set it up
  8. Choose YouTube Video as your trigger type
  9. In the capture selection make sure all four checkboxes are checked:
    1. Start
    2. Complete
    3. Pause, Seeking and Buffering
    4. Progress
  10. When you check the Progress option a radio button will appear. Leave this as Percentages.
  11. Fill in 25,50,75 into the textbox. This will track when the user has watched 25%, 50% and 75% of your video.
  12. Check the checkbox for Add JavaScript API support.
  13. Save the Trigger.
  14. Save the Tag.

You’ve now completed setting up YouTube video tracking on your site. Publish your changes and soon you’ll see data start to populate Google Analytics. You can now use these events in dashboards and to set up conversion goals.

If you have any questions about video tracking on your site, please get in touch.