Set Up Google Analytics Event Tracking for Site Customization

  • Updated

Context

To get additional attributes within Google Analytics (GA) for your site visitors to your customized site experiences, send events to GA through Site Customization. You can pivot on additional primary dimensions or add secondary dimensions such as Company Name as you would in standard reporting from GA.

Prerequisites

Steps

1. Access NewPersonalization.png Personalization > Site Customization from the left Navigation bar, select the Tracking tab, and select Create a New Tracking Event

GoogleAnalyticsTrackingSetUp.png

2. Enter the Event category, Element selector, Event type, Event label, and Event action.

Use the following event hierarchy for all messaging with personalization:

  1. Event Categories
  2. Event Label
  3. Event Action

Event Category

A category is a name that you supply as a way to group objects that you want to track. Typically, you will use the same category name multiple times over related UI elements that you want to group under a given category.

  • Recommended naming convention: Demandbase – Personalization
  • For more information, see Google Analytics Help: About Events

Element selector

Copy and paste the element id from the Visual tab on the Site Customization > Experience builder.

Event type

You can choose between two types of events:

  • View: If an experience is viewed, this will trigger a tracked event into GA. We recommend adding this event type for every experience.
  • Click: This option can be used when personalizing a click event such as CTA button. Once selected, you will need to add the html id for the element you are personalizing, which you can see on the Advanced tab of the Experience Builder in Demandbase.
NOTE: The Event Type you set in the platform will not display as a metric or value in GA.

Event label

Use labels to capture additional information for events that you want to track.

  • Recommended naming convention: [Experience Name]
    • By using the experience name for event label, it makes easier to filter within GA
  • For more information, see Google Analytics Help: About Events

Event action

Use the action parameter to name the type of event or interaction you want to track for a particular web object.

  • Recommended naming convention:

View - [Page Name]

Click - [Button Name]

  •  For more information, see Google Analytics Help: About Events
NOTE: Event Category, Event Label, and Event Action are completely optional in terms of what you would like to use.  These are field names that GA will pick up once fired, and allow you to pivot on.

Outcome

Navigate to the events view in GA, on the left hand side and select Behavior. Under Behavior, use the Events drop-down to drill down by page and dimensions.

 

 

 

You will see results for all of your Event fields in the Primary Dimensions area of Pages view in GA.

 

From here, you can pivot on these primary dimensions or add secondary dimensions such as Company Name as you would in standard reporting from GA.

You will also see a Demandbase API call but this is not the event tracking, it is a standard API call class="s3".

GA will not immediately reflect event data in Pages view. Typically the overview will reflect data first, and the more detailed information will follow in additional view options after it's been processed by GA.

Was this article helpful?

0 out of 0 found this helpful