As we discussed, event tracking can help you use a data-driven approach to optimize your PPC landing pages, e-commerce product pages, blog posts, lead generation campaigns, and affiliate marketing. Just remember that a goal completion applies to the entire session. That’s why it’s called data layer.). Once you place the GTM container’s JavaScript Snippet in your website’s source code and a visitor lands on your site, Data Layer is automatically initiated by Google Tag Manager’s snippet. Now, let’s check whether the developer passed an additional key you asked for, plan. You can use the developer tools to understand if there is a problem with Google Tag Manager. With dataLayer variables, there’s an easy way to access nested values. Once in a while, I see questions online that ask how to create a data layer. “One of my favorites is content grouping in Google Analytics combined with Google Tag Manager. Able to get custom dimension passed in GA via events but not page view? #3. The Data layer is one of the key concepts in the world of Google Tag Manager. Businesses of any size can potentially benefit from GTM. You’ve successfully implemented Google Analytics with Google Tag Manager. Check its value. Check GA Real Time Events to see this event come send data to Google Analytics. A data layer is an JavaScript object that contains all of the data that you want to pass to Google Tag Manager from your web page. Considerations for using Google Tag Manager. You say that: "It’s very important that dataLayer snippet is placed above Google Tag Manager’s container code in your website’s code. 3. 17 Ways To Fix It. Choose the Track Type (i.e. The entire concept of the event tracking in Google Tag Manager is based on the Data Layer. Trigger: A trigger listens for certain events, such as clicks, form submissions, or page loads. If I make changes to tags in my container, what is the affect on users in a current session? That’s how you can transfer additional data from Google Tag Manager Data Layer to Google Analytics. This means that we will send events about successful registrations to GA, Event Action: {{dlv – plan}}. Along with several other new marketing technologies, one that has seen a massive growth in last years is the Tag Management space. Also, this guide is quite useful for developers to better understand how to work with the Data Layer. 'ecomm_totalvalue': '415.83' }); The entire concept of the event tracking in Google Tag Manager is based on the Data Layer. Enter the following settings: If you’re not familiar with what is Google Analytics Settings Variable, read this guide. Your email address will not be published. If the snippet is placed after the GTM container code, Data Layer’s data won’t be fetched by Google Tag Manager. - URL of a website you're working one. Additionally, we’ll pass the value of the plan (pricing plan to which a user signed up). However, if you have Google Tag Manager, you can just add a new tag to your Tag Manager to track the downloads. If we see the above figure, the variable event holds the gtm.dom. It just requires some time. window.dataLayer.push({ How does Google tag manager Data Layer work? images, videos, length, title length) lead to the most conversions, longest time on page, etc. Let’s continue with our example of registration tracking. That wraps up the basics of using Google Tag Manager for event tracking. Then, we'll examine variables (aka macros). Please ignore the registrationCountry key in the screenshot above. What is the Data Layer? Here’s how GTM and Data Layer work in a nutshell: In many cases (at least from my experience), Data Layer is not commonly known among developers. You need to create a custom dimension pricingPlan in order to inform Google Analytics about this new parameter. I have checked the GTM Debugger that all of the values are being passed to GA (with the correct dimension indexes) and I can see "activity" in GA (so the GTM > GA passthrough is clearly working). Once this information is added to the Data Layer, Google Tag Manager can fetch it and transfer it to Google Analytics. Would they not yet propagate? We’re going to come back over here to Google Tag Manager. Click it and check whether your GA Event tag is fired. This can be done with the help of the Data Layer Variable. Maybe that variable you use for the Custom Dimension is not available on Pageview Trigger? Next navigate to your website. Data Layer declaration vs dataLayer.push. I mean, should they use the, You have a newsletter signup form (which cannot be easily tracked with usual. Google Tag Manager Tutorial for Shopify. Enter in an account name and click continue. Organize Your Google Tag Manager Efficiently from the Start. The snippet could look like this: By default, Google Tag Manager does not recognize custom data in the Data Layer thus you cannot use it as variables. Start record click to call data in minutes with this easy guide. The debug console will open at the open of the browser window. So once you reach the point where a developer pushes the interaction data (together with the event key) to the Data Layer, the next step is to catch that .push and turn it into a triggering condition. gtag('js', new Date()); gtag('config', 'AW-9.......6'); Evaluate what tag are being fired on the page and which ones are not fired. Back to custom event tracking. Any tags that are fired from Google Tag Manager should be migrated to Google Tag Manager, not just duplicated (for more information about migrating tags, see Migrating Tags to Google Tag Manager). Now, navigate to the site where the Google Tag Manager container code is implemented, refresh the page and a debug console window will appear at the bottom of your browser, showing detailed information about your tags, including their firing status and what data is being processed.. The best way to check if custom dimensions are properly passed is to use GA Debugger Chrome Extension. . I just changed the trigger to All Pages to DOM Ready and it pulled the information. Enable the Preview and Debug mode in your Google Tag Manager container, register on your website (just like a regular user would do that) and take a look at the debug console. First, you need to send data to Data Layer, then this data is fetched by Google Tag Manager. A developer has implemented our request and we checked that in the Preview and Debug mode (Data Layer tab), Track type: Event. I'll be resuming my intermediate GTM course very soon! Google Tag Manager uses these concepts to handle how tags are configured and fired: Tag: A tag is code that send data to a system such as Google Analytics. We can keep this private, you are free to send the information to julius[at] analyticsmania.com. In GTM, go to Tags > New > Universal Analytics. If unfortunately, registrationComplete is missing, contact the developer and tell him/her to properly follow your instructions. Manage all your tags in one place for a smarter, simpler way to oversee your marketing. This is the Data Layer code that must be added above the GTM container: If you’re not comfortable with touching the website’s code, a developer should do that (and in most cases, he/she will, in fact, have to do it. Click the button again and check Google … There are templates for non Google services such as AdRoll Remarketing or Click Tale heatmapping. Hi Julius, thanks for the awesome article! Let’s say, you want to implement Google Analytics Ecommerce Tracking. Click Tag Configuration. Marketing is getting more and more sophisticated. Hey, your setup will work fine. The final step. After it I have the event snippet for dynamic remarkting, which pulls the variables I need for that. If you already had a GA Pageview tag in your GTM container, there’s no need to create a new one. Step 8: Publish your Google Tag Manager container Click the red “publish” button in the top right-hand corner. The Data Layer is Google Tag Manager’s central repository of structured data. Let’s pull out the gender from the contact form. a user ID, the information about the clicked element, purchase ID, page category, etc. There’s also a noscript part that exists. I don't understand the example "using data from the Data Layer in GTM and GA". Let’s send an event to Google Analytics every time a registrationComplete event is pushed to the Data Layer. You don’t need to add anything additionally. Easily access and use the Tag Manager API through Google Apps Script. Check the response codes to see if there are any errors. This data will be sent by way of a new Google Tag Manager custom template, and it will comprise statistics of all the tags that have fired on your site for any given dataLayer event. Enter a name for your tag at the top of the screen where it says Untitled Tag. To see some examples of what can be tracked in Google Analytics. In this section of our Google Tag Manager Tutorial, we'll look at how tags (aka analytics or marketing scripts) work.. We'll also talk about how triggers (aka the rules) activate your tracking tags. links, forms) and custom event (e.g. I never use it. #1. Hi. I created the Custom Dimensions in GA (using the same Index values). If pricingPlan is undefined, you should double-check whether you have entered a correct Data Layer Variable name in GTM’s admin panel (by the way, it’s case-sensitive). What I did: I checked Debug Console Mode. This way Tag Manager will recognize the parameter. But if you know how, it’s fairly simple to view what’s in it. You can connect GTM with A LOT of other online tools (but we’ll talk about that in other blog posts). It might be a 3rd party plugin, some custom code created by your developer, even Google Tag Manager itself can push the information from the Data Layer. If you want to capture interaction and fire a particular tag (e.g. The data layer is the source of a vast amount of customer interaction data, website-related data and campaign data, which fuels the tag management system. Migrating to Google Tag Manager definitely has its advantages and I highly recommend that you do so. Enable the Tag Assistant and refresh your browser. To decide when to fire a tag (in the shape of triggers because you can use, All my Google Tag Manager Data Layer variables titles start with “dlv” (it’s easier to keep everything in order. Therefore, if you just tell a developer “add product information to the Data Layer”, there’s a high chance that a developer will have no clue what you’re talking about. All other cookie-setting tags must be handled as described below. If you want to capture interaction and fire a particular tag (e.g. Is it possible to do such a combination? This means that 5 registrations of the same user during the same session will be counted just as a single goal. Once you do that, the registrationComplete Data Layer event will appear in the preview mode. When the Variable is resolved, it will return whatever was most recently pushed into the key. Click Variables and look for pricingPlan. We have a basic understanding of the tag manager lingoes. That wraps up the basics of using Google Tag Manager for event tracking. Also, with it, you can push events to the Data Layer that can be later used as triggering conditions. Using Google Tag Manager effectively. Visit your homepage (or any page on your website) Right-click … How Google Tag Manager Works. You can then see which elements of your blog posts (e.g. Of course, it takes a while to understand how everything works, but once you get the idea, you’ll start putting puzzle pieces together. This is not a topic that can be covered by a quick 500-words blog post. 2. In this example, I will not go into detail on how to create a tag, I will only demonstrate how to pull the author data from the Data Layer and turn it into a variable (within Google Tag Manager). When an event is detected that matches the trigger definition, any tags that reference that trigger will fire. 'ecomm_prodid': '1.....8', It’s impossible to gain any insights … GTM: Passed a custom dimension along with a page view. One of our sharpest web analysts, Andy Gibson, recently wrote a blog post about Google Tag Manager and Google Analytics Premium for Enterprises on a high level and the value behind these tools, especially when used together. Get lead scoring data right in Google Analytics with Google Tag Manager Ruth Burr Reedy, VP of strategy at UpBuild, on the benefits of setting up lead scoring in Google … Technically speaking, a Google Tag Manager Data Layer is a JavaScript array that temporarily stores the information you need and then Google Tag Manager uses that data in tag/triggers/variables (later that data can be transferred to other tools, like Google Analytics). In this case, your developers should add a dataLayer snippet above the Google Tag Manager container with the following parameters: transactionID, transactionTotal, etc. It holds information you want to process in an object that can be read by Google Tag Manager, where it then gets pushed to Google Analytics. Tracking Virtual Pageviews with Google Tag Manager is really easy to implement, and fast to do. Let’s check if Google Tag Manager catches pricingPlan variable. Remember, GTM works best when deployed alongside the data layer (in fact, broken data layer = severely crippled GTM). If you have a page view tag that loads on every page such as Google Tag Manager you will see this as a part of the tags that are fired on your pages. Now it’s time to head to Google Tag Manager and enable the built-in variable. ", However, previously, you have mentioned that dataLayer.push can be placed anywhere in the code (above and below Google Tag Manager container) and it will not break the event tracking within GTM. So, you should routinely perform a quality check to check that its firing the script tags. As you can see from the screenshot below, the developer did a good job as I can see the plan key in the Data Layer. Usually, in the software world, the word Environment is used in the context of where the particular feature is being tested/reviewed. But since our main topic today is Data Layer, let’s focus only on the , 3)