By clicking “Accept All Cookies”, you agree to the storing of cookies on your device to enhance site navigation, analyze site usage, and assist in our marketing efforts. View our Privacy Policy for more information.
Creating Custom Tracking Events in Google Analytics 4: A Step-by-Step Guide

Creating Custom Tracking Events in Google Analytics 4: A Step-by-Step Guide

5
min read
Published on
August 24, 2023

Introduction

As your number one Webflow Expert agency, we get asked a lot by clients how to track events in Google Analytics 4, so we’re here to tell you!

Understanding how users engage with your website is a cornerstone of effective online strategy. By gaining insights into their behaviours, you can refine your approach and enhance your business outcomes. One powerful tool for achieving this is Google Analytics 4, which empowers you to track user interactions in a way that suits your specific needs.

In this comprehensive guide, we will paddle you through the process of creating a new tracking event when a user lands on a crucial page of your website - the whole process should only you 5 - 10 minutes, easy! Whether it's the pivotal checkout page or any other key destination, learning to set up custom events will equip you with actionable data to optimise your online presence.

Regardless of if you're a marketing manager, a business owner, or someone else tasked with managing these aspects, the step-by-step instructions provided here will empower you to create custom tracking events that align with your objectives. This is also super easy to implement within Webflow.

Let's get started on your journey to harnessing the power of customised event tracking!

Setting Up a New Event in Google Analytics 4

  1. Access your Google Analytics account by logging in.
  2. Ensure you have chosen the correct property, in this case, it will be the website that you’ve applied the Google Analytics 4 tracking code to. 
  3. Navigate to the ‘Configure’ tab and then click ‘Events’.
  4. Here, a list of events that occurred within the specified time frame will be displayed.
Note: Default user interaction events are automatically recorded by Google Analytics (e.g., session_start, scroll). They will only appear once they occur. For a comprehensive list of events collected by Google Analytics 4, refer to the official documentation.
  1. To create a new event when a user visits a specific page, click ‘Create event’.
  2. On the following screen, click ‘Create’.
  3. Now, you’ll be on the event configuration page. On here you need to enter the following details:

a. Custom event name: Describe the user action on this page (e.g., "begin_checkout" for the checkout page). If you want some more help setting your custom event name, you can follow Google's event naming guidelines.

Here are a few examples of other events you could track:

  • Add_payment_info: This records when a user enters payment information. 
  • add_to_cart: This will keep track of when products are added to the cart.
  • view_cart: This monitors when the user visits their cart.
  • tutorial_complete: This event records when a user completes a tutorial.

b. Matching conditions:

  • Set event_name to equal page_view.
  • Set page_location to contain [insert_page_url].
Important: This guide uses the checkout page as an example, assuming the URL contains ‘/checkout’. Replace ‘/checkout’ with the desired URL for tracking on your site.
  1. Once the event configuration is complete, click ‘Create’.
  2. The newly created event will now be visible. Hit the exit button to go back to the events dashboard. 
  3. Now, any future visits to your checkout pages will be recorded in the event dashboard.
  4. If you want to track this event as a conversion or goal, you can mark it as such by clicking the switch in the ‘Mark as conversion’
  5. Note: be sure to only mark actions considered significant, such as purchases or form submissions, as conversions.
  6. And voila! You have successfully created a new tracking event in GA4.

Verifying Event Setup in Google Analytics

Ensuring the accuracy of your lead tracking is paramount for effective data analysis. This guide will take you through the steps to verify your event setup in Google Analytics, guaranteeing that your tracking mechanisms are functioning as expected. By employing these simple steps, you can confidently assess real-time event data and make informed decisions based on accurate insights.

  1. To be able to verify if tracking is working in real time you will need to install the GA Debugger Chrome Extension.
  2. When it has been successfully installed, activate the extension by clicking on it and ensuring it is on.
  3. Log in to your Google Analytics account.
  4. Navigate to the ‘Configure’ tab and select ‘DebugView’.
  5. Once here, you’ll see that DebugView displays real-time tracked events in Google Analytics 4.
  6. Here then, you can start to test the custom event by visiting the corresponding web page.
  7. You should see the custom event monitored in DebugView if the lead tracking is successful.

Editing an Event in Google Analytics 4

Here, we'll walk you through the simple steps to modify event settings and variables in Google Analytics 4, allowing you to tailor your analytics data to your specific needs.

  1. Log in to your Google Analytics account.
  2. Select the appropriate property with the Google Analytics 4 tracking code implementation.
  3. Go to the ‘Configure’ tab and choose ‘Events’.
  4. Select ‘Create event’.
  5. Go to the previously created event and click on it e.g. in this example, the event would be ‘begin_checkout’.
  6. Edit the event variables as needed and click ‘Save’.
  7. There you have it, you’ve edited your event.

Deleting an Event in Google Analytics 4

In this section, we'll walk you through the process of removing events from your tracking setup with simplicity and precision. By following these straightforward steps, you'll be able to seamlessly remove events that are no longer needed, ensuring your analytics data remains streamlined and relevant.

  1. Log in to your Google Analytics account.
  2. Choose the relevant property where the Google Analytics 4 tracking code is implemented.
  3. Access the ‘Configure’ tab and click ‘Events’.
  4. Select ‘Create event’.
  5. Find the previously created event and click on it.
  6. Go over to the top right-hand corner and tab on the kebab menu (the three vertical dots) and select ‘Delete’.
  7. The event will be deleted, and you'll be directed to the create events page.

Conclusion

Tracking user engagement unlocks a wealth of actionable insights that can drive your business forward. By setting up, verifying, editing, and deleting events, you can fine-tune your data collection to align with your goals, enabling you to enhance online strategies and decision-making and positively impact your business trajectory.

If you want to learn more about GA4 and how you can track custom events, get in touch, we’re always happy to help!

Ready to Get Started?
Ready to take the next step? Send us a message or give us a call to discuss your project today!
01637 838 159