The more you understand the behaviour of your users, the better you can market your product or service — which is why Google Tag Manager (GTM) is a marketer's best friend. With built-in tag templates, such as scroll depth and click tracking, GTM is a powerful tool to measure the engagement and success of your content. 

If you’re only relying on tag templates in GTM, or the occasionally limiting out-of-box Google Analytics[1], then you could be missing out on insights that go beyond normal engagement metrics. Which means you may be getting an incomplete story from your data.

This post will teach you how to get even more insight by setting up cookies in GTM. You'll learn how to tag and track multiple page views in a single session, track a specific set number of pages, based on specific on-page content elements, and understand how users are engaging with your content so you can make data-based decisions to better drive conversions.

Example use case

I recently worked with a client that wanted to better understand the behavior of users that landed on their blog content. The main barrier they faced was their URL structure. Their content didn’t live on logical URL structures — they placed their target keyword straight after the root. So, instead of example.com/blog/some-content, their URL structure looked like example.com/some-content.

You can use advanced segments in Google Analytics (GA) to track any number of metrics, but if you don’t have a logically defined URL, then tracking and measuring those metrics becomes a manual and time-consuming practice — especially when there’s a large number of pages to track.

Fortunately, leveraging a custom cookie code, which I provide below, helps you to cut through that time, requires little

Read more from our friends at the Moz Blog