How to Add Basic UTM Tracking to Your Design Template Using Google Analytics
Being able to track where your users are finding your events is an invaluable insight for marketing, no matter your business size. Urchin Tracking Modules, commonly referred to as UTMs is the standard way to track this information and pass it to your preferred data tracking tool of choice. This guide will show you how to add this capability to any of your design templates!
This guide uses Google Analytics 4 to show how tracking works, but other tools, such as Hotjar or Mixpanel would work as well. For those tools, make sure you read their documentation for what code needs to be added to your design template.
Create a Design Template
-
Create a Google Analytics Account and create a new data stream.
-
Create a design template by following the steps outlined here in this help doc: Event Landing Page Designs
-
Copy and paste the below code block into your design template's Header code box.
-
Replace the two "[YOUR GOOGLE MEASUREMENT ID NUMBER]" in the below code snippet with your Google Analytics Measurement ID Number.
-
<!-- Google tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id=[YOUR GOOGLE MEASUREMENT ID NUMBER]"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', '[YOUR GOOGLE MEASUREMENT ID NUMBER]');
</script>
Note: UTM data can take up to 48 hours to reflect on your Google Analytics reports.
Adding RSVP Tracking with Your UTMs
The below script checks if someone has RSVP'd to your event and sends that back to Google Analytics as well, along with your other UTMs, so you can see who has RSVP'd to your event and how they got to your landing page.
- Copy the below script and paste it into your design templates's Footer input box:
<!-- Include: Callback script -->
<script async src="https://cdn.addevent.com/libs/evt/js/events.tracking.ga4.utms.rsvp.callback.v1.js"></script>
Please ensure that you have saved your design template. Once saved, you can apply the design template to your event landing page by following the steps provided here: Apply an Event Landing Page Design Template to an Event
Updated about 8 hours ago
