Google Tag Manager | Basic Tutorial

Google Tag Manager

How To Set Google Tag Manager for Basic Goals in Google Analytics:

Creating Google Tag Manager Account:

Create new Account in Google Tag Manager, which you can name with your website / client / project.
Account (the highest level of the structure) = Website (most common for SEO companies).

Add new Account:

The Account name and the Container name can be equal, no problem.
=> Choose Where to Use Container – mark Web (in most cases for websites).
=> Accept Google Tag Manager Terms of Service Agreement.
=> Then we get the Google Tag Manager code which we have to place it immediately after the opening <body> tag.
IMPORTANT: If you have an existing Google Analytics tracking code on this place, move it before the closing </head> tag where is the recommended place for the analytics tag.
IMPORTANT: Before creates your first Tag go to the Variables menu below and enable Built-In Variables which you will use for your future goals. Then start with the creation of your tags.

Google Tag Creation:

  1. Create New Tag.
  2. Give to your Tag unique name which reminds you for its functionality.
  3. Choose Product to which we want to send information – set Google Analytics (for conversion analysis).
  4. Choose a Tag Type – set Universal Analytics.
  5. Configure Tag:
    1. Set Tracking ID field – put the Tracking Id number from Google Analytics Property which you want to track
    2. Set the Track Type:
      – If you choose Event, you have to add Category name and add an Action.
      – For this type of Track Type, you don’t have to add Label and Value.
      – On the tick Non-Interaction Hit – set True (to not reported action without interaction).
      – For these types of main goals, you can miss the menus with More setting and Advanced settings.
      – Then click Continue.
  6. Set when the Tag will Fire On:
    – If you want to measure clicks – choose Click and then you have to set the Trigger for this event.
  7. Create Trigger:
    – Give the trigger unique name.
    – Choose event – Click (for example).
    – Then Configure Trigger target – set All Elements.
    – And set to Fire On – Some Clicks.
    – Now you have to set the firing of the trigger when an Event occurs and all of the existing conditions are true.
    – The first field is the variables which we set before to create a trigger. Then you choose the type of the variable. In this case, you can use Click Classes and use the individual class of the button which you want to measure.
    – The individual class (for example – single_add_to_cart_button) add in the third field. This is the most popular option, but here we have more options too. We can use a part of the single URL if we want to measure a single product or individual ID of the button but in these cases, we have to set another variable. The platform gives to us a lot of options. For the most accurate realisation use class.
    – In the middle field, we set the condition when the variable will be complete. The possibilities are a lot and they depend on the different goals. In this case, choose “contains”.
    – Then create the trigger but DON’T SAVE THE TAG.

IMPORTANT: Before creates your first Tag, go to Google Analytics account and create your Goal. You will link the Goal with the Tag but the Goals in Google Analytics have to be created before Tags in Tag manager!

  1. In Google Analytics go to Admin menu => Set the View for which you want your goal => Goals = > New Goal.
    – On the Goal Setup – select “Custom” – the last option, then Continue.
    – On Goal description – add the name of your Tag (it’s important to match to work properly).
    – Choose the Type of the Goal – in this case, Event, then Continue.
    – On Goal details set the Event Conditions and add the exact match names of the Category and Action. Other fields left empty.
    – On Use the Event value as the Goal Value for the conversion – set YES and SAVE the Goal.
  2. Now you can Create your Tag in Google Tag Manager.
  3. Publish the changes with the top right red button.
  4. Go in the Google analytics Reporting menu to check if everything works => click Real-Time => Conversions.
  5. Refresh the website product page => click on the “Add to cart” button => the go back in the Analytics Real-Time Conversions and you have to see your Goal Hit in the timetable.

Other Track Types:

  • If you choose a Page View condition, you can measure you single page visits. For example, you can see how many users visit your /checkout page and how many of them make a buy and brings to your /thankyou page.
  • Here you don’t have to add Category name and Action – only click Continue.
  • The set the Tag Fire On – Some Pages.
  • Then have you create your trigger for this page with its unique name.
  • Set Variable – Page URL.
  • Set Operation – contains, equals, start with, end with – it depends on the goal and specific URL.
  • !Save the trigger, but don’t save the Tag!
  • Go in Google Analytics and create a new Goal.
  • Select Custom Goal setup.
  • Set Goal description name – equal to your tag name.
  • Set Goal description type – set Destination and Continue.
  • Set Goal details – destination is your URL – you have to decide what to set – Equals to, Begins with or Regular expression, depends on our goal.
  • Value and Tunnel buttons above set to – OFF.
  • Save you goal in Google Analytics, then save your Tag in Google Tag Manager and PUBLISH it.
  • Check if your goal is working in Google Analytics conversion reports.

To Be Continued…

Comments are closed.