Google Tag Manager – Google Analytics

Last time I wrote short summary about how to start with Google Tag Manager (GTM). Now it’s time to add our first tag to make GTM works for us. Let’s start with Google Analytics tag.

Google Tag Manager allows you to deploy Google Analytics using the Universal Analytics tag or the Classic version of the tag.

Source: Google

What do we need to start?

  1. Google Tag Manager with new account created (that’s how to do it)
  2. Google Analytics account with tracking ID (start with Universal Analytics)
  3. Access to your webpages source code? – not this time – do you remember why we use GTM? – to be independent of the IT department!

Tags, triggers, variables and data layer

It is important to understand the difference between these concepts:

  • tags – snippets of code that executes on a page
  • triggers – you attach triggers to tags to specify when they should fire
  • variables – help define triggers and what data they send
  • data layer – optional JavaScript object that you can use to help manage the information your tags are gathering from your site

https://www.youtube.com/watch?t=34&v=7FXbsCWsEi8

Adding Google Analytics Tag

  • choose proper account in GTM and click “Add new tag

    Adding new tag
    Adding new tag
  • choose “Google Analytics” >> Continue

    Google Analytics tag
    Google Analytics tag
  • choose “Universal Analytics” >> Continue

    Google Analytics tag - Universal
    Google Analytics tag – Universal
  • add your Google Analytics tracking ID, and choose Page View track type >> Continue

    Google Analytics tag - tracking ID
    Google Analytics tag – tracking ID
  • now we have to define when Google Analytics tag should be fired – in that case it should be “All pages” – that’s trigger for tag >> Create tag

    Google Analytics tag - fire
    Google Analytics tag – fire
  • choose name for our new tag (it’s up to you – choose Google Analytics or whatever you want) >> Save

    Google Analytics tag - name
    Google Analytics tag – name
  • we are almost done here – our first tag is ready for publication with rule (trigger) when it should be fired

    Google Analytics tag - tag is ready
    Google Analytics tag – tag is ready
  • so let’s publish it!
Publish
Publish

I highly recommend testing new tags before publishing (debug option) but that is subject for new post.

Done
Done

Success – our first tag is online and data in Google Analytics begin to be collected.

Join the Conversation

1 Comment

Leave a comment

Your email address will not be published. Required fields are marked *