Computing and Gadget, Consumer Electronic, Development, Service & Support, Information and Reviewers, Technology Sectors, Website & Design

Google Analytics 4 for Beginners Chapter 2

Chapter II: Event Tracking with Google Analytics 4

After installing GA4, it’s time to start collecting additional data.

Now is a good time to bookmark this Google Analytics 4 tutorial in case you need to refer to it later. We still have a lot to cover and if you don’t have enough time, feel free to check back when you’re ready again.

#2.1. Goodbye category, action and event tag

Compared to Universal Analytics, also known as UA (the old version of Google Analytics), the data model in Google Analytics 4 is much more flexible. This means there are fewer restrictions and required fields/parameters compared to UA.

The most notable difference from events is that in Universal Analytics you need to get/populate four fields that have to be sent for successful execution (excluding custom dimensions). These fields are the following:

Event category (required)
Event Action (required)
Event tag (optional)
Event value (optional)

In Google Analytics 4, the naming convention is much more flexible and only depends on the person implementing the tracking setup.

In GA4, there is a parameter called Event Name , so everything else depends on what you have planned. For example, let’s say someone filled out the “Request Demo” form on her website. You can send the following event:

Event name: request_demo
product_name : awesome product
company_size : 99-250
company_industry: internet and telecommunications
annual_revenue : 50-100 million

The last 4 items in the list above are custom parameters that you can send along with an event. Note, however, that there are some limits to the number of custom parameters you can send with a single event.

If you’re not sure how to name/structure events, we first need to learn about the various types/categories of events in Google Analytics 4 and how you can create/modify them. I think it’s important to have a good understanding of the events in GA4 before you start thinking about the structure.

#2.2. Four Event Categories in Google Analytics 4

Google Analytics 4 events can be divided into 4 categories:

Automatically collected events
Improved measurement events
Recommended events
custom events

The process of how you should plan the structure of your events (names and parameters) is by doing the following:

Make sure the event you want to track is among the automatically collected events
If not, check if your event is mentioned among the enhanced measurement events (for example, scrolling or file download)
If not, check the recommended events and their naming convention
If none of the above categories apply to your events, create a custom event with the event you want

In the next 4 mini chapters of this article, I’ll explain where to look and how to find your event category.

To summarize, this is the process of how Google Analytics 4 event tracking works:

Identify if your event is automatically tracked.
Otherwise, create a GA4 event tag in Google Tag Manager.
If necessary, also include the event parameters
Check input events in GA4 DebugView
Register event parameters as custom dimensions
Publish all changes to Google Tag Manager

Let’s see in detail the points mentioned:

#2.2.1 Category #1. Automatically tracked events

There are certain events that the GA4 tracks automatically. You can find a full list here. In this list, you will find web and app events. In fact, the list of web events is a bit longer than I expected. Enhanced Metering events are also listed there.

For now, we’ll temporarily ignore them and focus only on events that are auto-captured and shouldn’t be added to any other event categories. The list of events on the website is displayed as follows:

first_visit: This is the first time a user visits a website or launches an app.
session_start: When a user interacts with the app or website and starts a new session
user_engagement: This event fires 10 seconds after the visitor stays on a page. But it can also be triggered periodically while the app is in the foreground.

#2.2.2 Category #2. improved measurement

When you set up a web data stream in Google Analytics 4, you have the option of using enhanced measurement. It’s designed to help marketers include as many events as possible in their reports without having to work with developers or do any configuration in Google Tag Manager.

If you go to Admin > Data Streams > Select Web Data Stream, the following window will open where you will see a section called Enhanced Measurement.

By default, this feature is enabled and will automatically track the following events:

Page View (event name: page_view )
Scroll (event name: scroll)
Click output link (event name: click with output parameter: true)
Site Search (event name: view_search_results )
Youtube video (events: video_start, video_progress, video_complete )
File download (event name: file_download )

If you want, you can disable/enable events individually and you can do this by clicking the gear icon in the Enhanced Measurement section and then clicking the toggle buttons.

improved measurement

Also, some events can be further customized.

page_view: This event is sent to GA4 when a new page is loaded or the page URL is changed without reloading the page (also known as history change events)

improved measurement

scroll: This event is sent to GA4 once per page when a visitor scrolls below the page height threshold of 90%.

click: This is an event that refers to outbound clicks (when a clicked link redirects a visitor to another domain). Along with this event, an additional output parameter (with the value “true”) is sent.

If your company/project works on multiple domains, you can go to Tag Settings (from that same event stream) > Configure your domains and enter your company/project domains.

view_search_review: This event will be sent to Google Analytics 4 if the page is loaded and the page URL contains a query parameter such as q, s, search, query, keyword . But if you want, you can include more (up to 10).

improved measurement

If the address of the search results page of your website has this structure: https://www.yourwebsite.com/search?key=my+search+term , you have to enter the word “key” (without quotes in the search event configuration) . If the search results URL contains more useful parameters, you can include those as well.

For example, if the url of your search results page is displayed as follows: https://www.yourwebsite.com/search? key =search+term & results =50 , you can include the “results” (without the quotes) in the second field of the configuration. So this parameter will be automatically tracked by GA4.

video_start, video_progress, video_complete: Enhanced Measurement can track the interactions of the Youtube video embedded in your website and then send “video_…” events to GA4. But these Youtube video players must contain the ?enablejsapi =1 parameter in their URL. And this is not always available on websites.

file download. This event is sent to GA4 when a link is clicked and that link contains one of the following file extensions: .pdf, .xls, .xlsx, .doc, .docx, .txt, .rtf, .csv, . exe, . key, .pps, .ppt, .pptx, .7z, .pkg, .rar, .gz, .zip, .avi, .mov, .mp4, .mpe, .mpeg, .wmv, .mid, .midi, .mp3, .wav, .wma .

In other words, if the link opens/downloads a file. Currently, it is not possible to update the list with other extensions in the GA4 interface.

Once you’ve selected the events you want to track, click Save in the top right corner and make sure Enhanced Measurement is turned on.

From then on, your Google Analytics 4 will start tracking events automatically.
#2.2.3 Category #3. recommended events

As I mentioned earlier in this article, when trying to choose the name (and parameters) for your event, first take a look at the auto-tracked events (possibly these events are already being tracked) and then check Enhanced Metering. If none of these events meet your need, please refer to the list of recommended events.

Google has published several pages for different industries:

Generic (for all properties)
Retail/E-Commerce
jobs, education, real estate
Trip
Games

Consult each of these events and see if one of them meets your needs. For example, if you want to track when a user logs in, you’ll find the “Login” event in the “All Properties” list.

recommended events
#2.2.4 Category #4. custom events

Finally, the last category of events in Google Analytics 4. If you want to send an event and it is not mentioned among the auto-track events, the optimized measurement or the recommended events, you can create custom events.

Custom event settings are almost identical to recommended events. The only difference is that you will need to create your own event names.

For example, if you want to track contact form submissions, the event name could be any of these:

send form
Contact Form
send_contact_form

GA4 is completely flexible; however, there are some limitations regarding the maximum length of an event name. Additionally, there is a limit of 500 unique event names. If you catch up, Google says you won’t be able to track new events. And at the moment, you can’t delete unused events (which is pretty annoying). So be careful about creating too many unique event names.
#23. Event Limits in Google Analytics 4

Another thing to note is that there are some limits (and some are gone (at least for now?)) I always recommend that you check this page when it comes to limits.

Anyway, here are some of the things to keep in mind right now:

There is no limit to the total number of events (at least for now). In Universal Analytics (free account), the limit of visits allowed per property was 10 million. At the moment, there is no such limit in Google Analytics 4. But you never know what can happen in the future.
You can have up to 50 custom dimensions and 50 custom metrics registered on a property. The keyword here is registered. That means you need to go to Configure > Custom Settings and configure it there. If you send more custom parameters but they are not registered, no problem.
You can send up to 25 parameters with one event
There are also some length limits for event and parameter names. Both (event name and parameter name) must be up to 40 characters.

Related Posts