 All right, it's for 10, just about. I'm going to go ahead and get started because I'm sure everyone's eager to get out of here and get to the welcome reception at the end of the day. Thank you all for coming. We're going to talk today about how to get going with Google Analytics 4. Just a reminder, hopefully you got this from the session description, but today's talk is really aimed at beginner audience with what I had in mind. We're going to have a little bit of general background about Google Analytics and Tag Manager, what those are, why you might want to use them. If you are a developer or a site builder, there will be some parts that go over how to set it up and add it to your Drupal site. For those of you that might be more on the marketer, site owner, content editor side, there's also some things that you might want to consider about setting it up on your site. I think questions you might want to ask your developers or expect that they might ask you and just a little bit of a taste of what you see in the default reports once you get it added to your site. So it's a more specific outline of the topics. We'll talk about what Google Analytics 4 is, what Google Tag Manager is, then we'll go through and do the demo of how to set up the property and the tag to add to your site. And then to get it going with Drupal, the Drupal-sided things switch over to how to install and configure the Google Tag Module. And then after going through the setup steps, we'll look a little bit at what you get with the automatic tracking when you first install it and a little bit of a really simple example of how to add some custom event tracking to your site. So before I dive into that, just a little bit of background about me. I'm Heather Wozniak. I'm a technical strategist at Four Kitchens. I've been in that role for, I'll say, three years. I was at Advomatic for about a year, and then we merged, but essentially doing the same thing. Four Kitchens is a Drupal development design and strategy firm that really works to make the web a better place for everybody. We craft websites that help organizations really fulfill their mission. A lot of the organizations we work with are nonprofits or higher education organizations. And so in the last several months, I've been working a lot with our continuous care clients who had universal analytics on their site for a very long time. And then now they need to make this transition to Google Analytics 4. So that's where some of this is coming from. So what is Google Analytics 4? Like, you may wonder, why is it 4? Like, what happened to 1, 2, and 3? The universal analytics that we're all used to actually is version 3. It's been around. I was looking it up for over 10 years. So I think we've just all gotten used to it. We just think of that as the standard. But that's actually a third iteration of that product. And so this one, version 4, is the latest and greatest. You may have seen, if you are currently using universal analytics, some form of this message, right? In emails to you, when you log in, there's friendly banners, sometimes not so friendly warnings that are in your face. They're doing their best to let everybody know that July 1st, things are going to change. And you need to make a switch if you want to continue using the analytics product to get information about your site. Some of the key differences between Google Analytics 4 and the previous version that we're used to is that the new version, which, if you read their documentation, Google calls it the next generation of analytics. It can collect data both about websites and apps, which can help you better understand the customer journey through your product if you have integrated system with all of those things. It's also now events-based rather than session-based. And by events, we mean actions that users are taking on your site. So it's really looking to track what humans people do, and they get information about that. And then lastly, it has more enhanced privacy controls and predictive capabilities to go along with that. Because I think a lot of these changes are driven by privacy regulations and the fact that cookies are going to go away. And we can't just monitor and track everything about all people all the time the way we used to. So there needs to be some technological changes to actually respect that and make that possible. And to fill in the gaps where we can't track, that's where the predictive part comes in. Yeah, I don't know. I think I just said human. Let's do questions at the end. We can come back to that. OK, what is Google Tag Manager? OK, so that was analytics. Google Tag Manager is another product from Google that it's a way you can add tags to your site if you're thinking, what is a tag? We use that word tag in a lot of ways when it comes to websites. In this context, it basically means kind of a snippet of custom code that you want to add to your site for some reason. Often, maybe under certain conditions, maybe there's a snippet you need to add on some pages, but not every page. Sometimes you do need to add it to all the pages. And so what Tag Manager does is it gives you a web-based interface for managing all of these little snippets that you might need to add to your site. So that's cool because it means you don't necessarily have to work with developers to make changes directly in the code that runs the site all the time. And then it also gives you a way to, if you have a lot of tags, to categorize them, name them, and even version control, so you can add them and test them out with a debugging tool and make sure it's working first before you publish it and make it live on your actual site. Also with that, you're able to have access to templates that have been made by other users and companies that have products that integrate through tags and they'll give you a template you can use to add it to your site. And then collaboration features, so you can give access to other people at your organization and it's not just on a single person to manage all the different tags that you're using. Some of our clients work with, like, marketing firms or ad agencies, and so they're able to give them access to their Tag Manager setup so that they can add tags and manage that on the site on their behalf, so that's great. And then lastly, it's not just for Google, like we're talking today about analytics and ads is another product that gets used a lot, but you can add other kinds of third-party tags as well, so Facebook, Pixel, LinkedIn ads, sleek note pop-ups, like there's all kinds of things these days that might require you to add some tags, some piece of code on your website to get it to work, and so this provides a system for managing all of that. One thing I wanted to clarify about the terminology in talking about this and reading about it, I feel like I see these Google Tag repeated over and over, but it sometimes means different things, different contexts, so Google Tag Manager, as I just described, is this web-based tool for managing tags and triggers, but there's also, as we'll see, a Google Tag module, that's a Drupal module that allows you to integrate that into your Drupal site. It used to be called Google Tag Manager, the module, the exact same name, but now it's been renamed to just Google Tag, and then also there's something called GTAG.js, which just also adds the Google Tags to your site. This is the JavaScript that's really technically doing the work of putting the script on the page, so these are all layers that are interrelated, but they're not the same thing, and sometimes it can get a little confusing which piece you're talking about, so just being aware that there are differences is a good start. So how do you actually add this analytics to your Drupal site? There are a few different ways you can do that. You can, of course, when you create the properties, we'll see in a minute, it's gonna give you a snippet and say, embed this on your website, put this in the head of every page. You can do that. There might be some cases where you would want to, but I generally stay away from that because it's not very flexible. It's just in the code. Sometimes you can forget that it's there. I've inherited some sites where there's multiple implementations of this because one team just added it and another team just added it, and so it can get messy. So I prefer to use a module. There is an analytics, Google Analytics module for Drupal, which is great if that's the only product and tag you're interested in using, but I just mentioned using the Google Tag system opens you up to be able to incorporate a lot of other third-party tags and products that way, so I feel like that's the better way to go than just the plain Google Analytics module. So as I said earlier, when you do it that way, you can support all different kinds of tags. You can be able to share responsibility for adding tags to the site without necessarily going through a developer. Sometimes you do need developer support if you need to set up custom class names or attributes or something on the page to connect with your tagging, but there's a lot of stuff you can do without having to work with the developers directly. And then because it's a Drupal module, you can do things like set conditions on whose activities you want to track. Maybe you don't want to do it for all user roles, only certain ones. Or maybe there's certain paths or sections of your site that are super private and you just don't want to track that at all because of privacy reasons. There's things you can configure which make it pretty powerful. And then also because it's a module, you can pretty easily just disable it in development and test environments. So if you have engineers are working on the site locally and loading it hundreds of times a day or QA testers, you don't get all that information, your reports, and making it look like your site has way more visits than it actually does. Okay, so now we're going to kind of do the demo portion where I made a couple short videos. Hopefully they cooperate and play so that I'm just going to kind of talk through what I was doing when I recorded this. I didn't want to do the live demo so I just pre-recorded it. But this first one is about just creating a Google Analytics 4 property. So this is starting from a site that already just a fake site that had a Universal Analytics property for. And so there's that begin migration button you could use or if you had that countdown clock, I just went to the setup assistant and going to say yes, I want to get started creating my new property and read the box. It's pretty straightforward. It's going to create a GA4 property for you, copy basic settings. I usually think that's a good idea I guess although sometimes you kind of wonder exactly what comes over. But I typically don't check the box to enable data collection using the existing tags because I want to go through the extra effort and the other steps in a minute to add the tags to the site in the new clean recommended way so that you don't end up with croft and old tags that you shouldn't have there. So when you do that, it creates it for you. It gives you the snippet if that was how you were going to add it to your page but I'm just going to skip that for now so I can just go ahead and click confirm and then go ahead and configure a few more the basic settings for this property. If I click there on the go to the property, then it gives me, oh, I wanted to point out that when you do this, you should turn off that automatically set up a basic Google Analytics 4 property, turn that off once you've set it up yourself because then it will stop sending you emails and reminders that this is going to happen automatically unless you take action. So that's nice if you want to get rid of all those emails. But coming back to the setup assistant page, this part is really important is setting up the data stream. There are a few things on here that I would recommend enabling and those are the enhanced measurement parameters. So by default, when you just first create the property, it's only tracking page view activities but you could see here there's other kinds of events that we could get data about scrolls, link clicks, site search, form interactions, video engagement, file downloads. I'm just turning them all out here by default. This is another thing where you have to stop and think about what you would want to use on your site. I feel like I had a slide earlier about that that I don't remember talking about. Sorry, but it was about you have to be more thoughtful when you set up Google Analytics 4 because things are always on automatically. Another thing that I'm pointing out in this video is a lot of times we get questions about how do we exclude internal traffic like IP addresses or IP ranges. So in Universal Analytics, that was done through a filter on the views. It's different in Google Analytics 4. You have to click through where I went to in the data stream setup. And then you can define some rules that will specify what your internal traffic is. This doesn't filter it out from the reports completely, but it allows it to be labeled as internal traffic. So then when you are looking at the reports in the report section, you could filter out that internal traffic if you wanted to. And the other thing that I just pointed out in this video is about unwanted referral domains. If you have a couple different sites where you're cross-linking to your own sites and you don't want to have that information in the list of referrers, that's where you would configure those domains so that they don't get included there. So those are mostly the only basic things most of our sites have worried about for this initial setup. So I'm gonna go ahead and close that and save all those changes and then go back to the complete setup screen because there are a few other things on here that we can configure. But actually what I recommend doing if you're just doing the simple setup is just going through and marking all those actions as complete because if you don't do that, every time you log in, you're gonna keep getting notices that your setup is not complete and you need to go configure things. And chances are for, if your site is kind of a simple basic setup, those things aren't applicable and you can always come back to them later or if you know you're using them, you might be able to go through there, answer the questions and configure it, but it's good to just check all those boxes off so that the system will consider your configuration as complete. So I think that's the end of that video. That's just getting the basic property setup. And then the second video I have is showing how we add it in tag manager to create the tag so that we're gonna be able to send information to that analytics property. This video is shorter. So here in tag manager, I logged in, I don't even have an account here. So the first thing that I do is just create an account for my demo account is what I just called it. And then the container, you're gonna set up a container for your site. A lot of times, if you're just using this on a single website, it's helpful to use the domain of your site as the container name. And this is for the web because I'm gonna use this on a Drupal site on the web. And then you can see, I had to accept the terms of service. And again, it gives me this code snippet that it wants me to embed in the head of the page, but I'm not gonna do it that way. I'm gonna be using the Drupal module. So I just skip that part and I can get my tag ID later. So we're just gonna add one simple tag right now to get the Google Analytics 4 configuration set up for the site. And you can see it's a pre-made tag type so you don't really have to do much to it. All you have to do is go find your measurement ID and add that into the field where it asks for the measurement ID. And then usually you leave this box checked that you wanna send a page view event when this configuration loads. There are some other advanced properties down there, but you won't need that if it's just your initial setup, basic setup. But now we also need to add a trigger to tell the system when this event should fire or what event should make this happen, the send information to Google Analytics. So the trigger, I just use the all pages page view so anytime someone views any page on the site, it's going to make this tag fire and send the information to Google Analytics about whatever actions the user is doing. So that is pretty simple to set up. But you do have to also publish it. So there's a preview option where like I said earlier you could test it out and see if it's working on your site. But since I haven't added the Drupal integration yet, there's nothing to test. So I know I'm just setting it up for the first time. I added my tag, I'm just gonna go ahead and publish it so that it would be working for any live environment too. Done with that piece. So we've got our Google Analytics property and now we've got the tag for it set up in tag manager. How do we get that working with our Drupal site? So that's the next piece here is about installing and configuring that Google Tag module. So there's a few different ways you can add modules to your site. I typically am using Lando doing it locally with Composer. So you can see here is just that simple Lando Composer require command to get the module. And then I use Drash to enable it. You can install it whatever other way you like to install modules for your site as well. And then once it's enabled, you would go into the UI and configure a few things for it. So the important thing is to add your container ID which we saw a minute ago when I created the container. There was an ID for that so I would get that from there. And then this is where you can also set it up to say, I don't wanna track activity about these certain roles. Now this is gonna depend on your site and the types of users you have. If you have a site where you have members and they're logging in and you wanna see their actual activity of members on your site, you would not wanna exclude that, right? So I think usually authenticated, you don't wanna just exclude all authenticated users. You wanna think about what are the roles that I care about. And in some cases you might say, actually I want my content editor and administrator activity included because I'm interested in how those people are using my site and the actions that they're taking. So we're gonna go ahead and include that. So you can set that there. You can see there's also some tabs where you could say not to include it for certain request paths on the site. If you have certain sections that are private or don't need to be tracked for some reason, you can set that all up. So this is where a lot of the flexibility of using the module comes in. But the main thing I always usually do is the roles. And then of course after you've configured it, you need to deploy that to your site. How you do that might vary whether you export the configuration, have it in the get whatever your deployment pipeline is, but you would make sure to do that too. But wait, we just looked at an example where you could filter or not include the Google tags based on the user role when they're logged into the site. But sometimes you also have another layer there where you have developers who are working on the site locally or testers who might be visiting the test copies of your site. So there's a few different ways you could make sure that you don't get information about those users into your analytics data stream as well. One thing you could do is use config split. If you're familiar with the configuration split module, I think if you're already using configuration split on your site to manage differences between different environments, then that's a good choice to go. Otherwise you're adding some more overhead for yourself to add the module and set up the splits and figure out how to manage that. Another way you could do that is by adding a condition in the settings PHP file that would basically check the server environment. So you have to have some way of checking the information about what server environment you're on. Is it local, is it a test server? And then based on that, you can just set this variable here to just an empty value. And so then when that happens on the site, it just won't try to load the tag on the page. So it's basically will disable it in those environments. But the new way that I found, which actually I think now is my preferred way because it's the simplest, is you don't even have to do that in the Drupal site at all. You can do it in tag manager by just creating a more custom trigger. So instead of firing for any page view on the site at all, it actually has to be a page view on the live domain itself. So this is an example of in tag manager, you create the custom trigger and you just say, like it's very super literal only on some page views and you could specify the domains or you can also set it up to have more than one if you had that situation. And so that's super easy, you don't even have to get involved with the code at all and you can really manage what environments it's gonna load on. Okay, so that completes the tour through the setup portion. This next bit is a little bit more information about what Google Analytics 4 will track for you automatically once you get it installed on your site. If you read their documentation, there are a whole bunch of these events that it says it will automatically collect data about these events. And you can see them here. I don't have to read them to you. And the thing is I put here it kind of collects this information is what I found in my experience. I feel like maybe I'm missing something like should be easier but I found in order to get the information you kind of have to do a few extra things. One is you have to make sure you actually enable that enhanced measurement settings in the first place. Like we saw a few minutes ago when I created the property you have to go into the data stream and make sure it's turned on or it's not gonna be sending that information about the activity on your site to analytics. And then the other thing I found is that even though there are all these parameters that are associated with those events they don't always show up in the reports unless you create custom dimensions to kind of pick them up. So for example, you have the file download event when users are downloading a file on your site you probably wanna know maybe the name of the file they're downloading or the extensions like the images popular, the PDFs. And that stuff isn't totally collected I found unless you create parameters that will capture it in the custom dimensions. And maybe afterwards somebody here knows better than me because I feel like they say it's automatic it should be easier it should just show up. So maybe I'm missing something but this is what I've found so far. So this is an example of the custom definition screen where I set up some dimensions for these things like the file extension, file name, form destination because they just don't show up I've found unless I do that. So a quick breeze through of the what the reports actually look like this one is cool and snazzy especially if you look at it live this is the real time activity report on the map all those little dots are pulsating so you can be like ooh look at the people in different parts of the world that are visiting my site I think some of those other bars are animated too but I'm not really sure like what's super what you do with like the real time information other than like cool people are looking at my site maybe I shouldn't take it down right now right but I don't know it's I guess it's validating to see people are on your site when you see stuff there. This is an example of like looking at the most viewed pages so if you're used to a universal analytics I think it was under behavior content something like that it's been a while since I've looked at universal analytics so you could see like you get a list of the pages and the number of views the columns are similar to what you would have in universal analytics but there's a little bit different here like we don't have bounce rate anymore and it's a little bit cleaner view I think the way that it appears you can see you can still show more rows on the page page through all of the results and there's some limited search filtering capabilities but it's different in universal analytics you could do like secondary dimensions and drill down a lot more and so far I haven't really found that to be the case here in Google Analytics 4 so this is just a page view so another thing about it is it's very boxy you come to a lot of these dashboards and there's information in what I feel like are these tiny boxes on the screen where I just can't always see everything which I find a little bit frustrating this is an example see these say link URL page location page refer those are some of those dimensions that I mentioned earlier where they're automatically collected parameters but I had to map them as custom dimensions in order to get them to show up like this when I'm looking at information about the click event so just sort of my summary just things that I've personally found so far the date ranges are easier to work with I feel like like there's easier to select and there's more options there so that's good but like I said, a lot of those boxes cut off information and there's not a very easy way to expand it and see like the whole name of the file or the whole name of the page and I've had some trouble drilling down into information in some cases though in others I found there's like a filter is right there for the dimension that I wanted to see and so it's easy to use so like I said, the subheading here I feel like it's just gonna take more practice and patience to get used to it and see how it works and they keep changing it all the time too so it should keep getting better. Okay, we're almost done I just have a short section here about how you would go about adding custom event tracking if you wanted to actually have a specific custom event on your site so my example is really super simple I have my website and I have this donate link there in my header and I wanna know how many people are actually clicking on that specific link so the first thing I need to do is decide that like what is it that I wanna know that people are doing on my site? Other things could be like newsletter signups or other buttons called to action things like that you might have so but in my case I wanna know how many people are clicking on this donate link and the unique identifier I have right now about this link is this is not great but I'm just gonna look for any link with the text donate because my site is very simple and I trust that I have no other links anywhere that say donate so what I do is in tag manager I add a custom trigger that says I want you to go off on clicks link clicks when the click text equals donate like I just said so to be more sophisticated you could do it on a class or an ID or like have multiple conditions in there for why it would fire but this is the basic idea is you identify activity that happens that would fire it and then when that happens I add a tag for a GA4 event and so that's nice those are the pre-built tag types and I can just say yeah use the same configuration from the page views that I set up as my default setup and I'm using their built in click event just the same event name but I'm gonna have a custom parameter that I'm gonna send when someone clicks on my donate link I'm calling this the donate action and I'm gonna say start because they clicked the donate link and they're going to the donation page and I'm imagining they're starting a donation so I could potentially create other donate actions that I wanted to put in there if I had like a system to follow them through but this is just for the basic idea but then I need to tell analytics that this event is incoming so it knows we can capture it and put it into reports so that's where I add the custom dimension and they give it a name and I say you're gonna be watching for this donate underscore action event parameter which I was sending to it earlier and so now when I go to my click event reports I get a box there that's gonna tell me about how many times this donate action occurred and I can see that three people started one person one total user me three times clicked the button to think about donating and then that was all I did for my testing so that's a very very simple example it can obviously get way more sophisticated and strategic but it's pretty easy to do through tag manager itself so my conclusion is just saying again like this is new like it's gonna go right every time nobody pays attention to the website until it launches so this is gonna happen with Google Analytics 4 on July 1st suddenly there's gonna be a wave of like oh universal analytics is really gone gone what am I gonna do about it and people are learning about it creating the best practices every time I log in I feel like something has changed so Google is iterating on it and hopefully getting feedback and listening to us and making it better so hopefully we continue to see that improve but I think we may also find it's the case that for a lot of users they might shift away from this and there might be just some tools that are require less thought to set up but still provide that like core essential data that certain types of audiences would want about this site then we might see more shifts to using those tools instead of this Google system which I hear is also a lot tailored towards ads and like people that are using the ads to drive traffic to their site and I know a lot of the clients we work with some of them do but some of them don't cause that's just the nature of the business they're in they're not buying ads to drive people to view like the requirements for the English major like you just don't buy ads to do that so that's it that's all I have for today we have probably some time for questions come back to your question if you wanna remind me what it was about I use the word humans yeah I think it is better I do remember reading that it's like the bot stuff is just turned off by default automatically in Universal Analytics there was a check box you had to go in and say like don't include bot activity and I think there's just no check box I think it just doesn't so they're doing something on their end to try to not include it okay question in the back you can have them both installed simultaneously which is what Google was recommending so you can start collecting new data in the four system so that July 1st when the other one shuts down you have like a bit of history to work with and we can kind of pilot and experiment and see what's happening so it should be fine to have both on your site at the same time it depends how you set it up but yeah I like to do one well that's why I like Tag Manager because you add Tag Manager on the site once on Drupal and then you can have both Universal Tag and GA4 Tag in Tag Manager and so when you're done with Universal and you want that to go away you can just delete that from Tag Manager you don't have to touch anything on your Drupal site but that's been a process to transitioning some of our clients who were not using the Google Tag module to remove either their hard-coded snippets or their Google Analytics module and replace it with Google Tag and set up the container and all of that. Go ahead. Yeah, I'm recording it in real time for the site so you can see as you're developing whether your code is correct. So let me repeat the question I'm supposed to be doing that for the recording so he's asking if when the event happens like click or page view does that get recorded in Analytics in real time? It shows up in the real-time report if you're looking at the real-time page but if you switch over to reports with the historical data it won't show up until the next day but in terms of testing and troubleshooting it will show up in the real-time section but then also the debugging tool Tag Manager has the preview debugger that you can turn on and so it'll show up for you there too and it gives you a lot of information about which tags are firing and what data parameters and things are included with it. Yeah. Yeah, personally I haven't seen any but I feel like I haven't really seen any. I hear some of my colleagues have been talking about it but I'm not sure if we have any clients that are using it but none of the ones that I personally have worked with. Yeah, the question was how many clients do we see using BigQuery? I'm trying to remember, I feel like some of them we just had the same one on all of them but I've seen the other data streams done as well. I haven't personally worked on that so I don't really have a very good answer for you but I know we've had, so my colleagues have had conversations about that. So you have three or more websites that recommend separate property? I think it depends what you wanna see in your reports too. Do you want all that data from all the sites aggregated together in one place? I have seen actually, some clients have two because they have one where there's like aggregating stuff from a lot of web properties together and then they have one that's like individual for a specific site, so I have seen that. Sure, so she asked if when you're setting up a custom event based on class or ID, does it work when that's in the shadow DOM? I don't, I haven't really like know if I've had a use case to test that out. I've done a lot just based on class and it usually works. I don't see any other hands up, so we can stop.