3rd party integrations
...
Purple Tracking
Tracking Services

Google Analytics

19min

Summary

Official websites

Site

URL

Website

Documentation

PXP implements two options that can be implemented on the web. These are:

Developer integrations

Platform

URL

Android

not supported

iOS

not supported

Web

PXP implements two options that can be implemented on the web. These are:

  • via Google Analytics 4*
  • via Google Tag Manager**

(*) Available since PXP 3.7.0

(**) Available since PXP 4.0.0

Tracking service

Event support matrix

Overview of the supported events and their configuration.



Templates

Parameter

Actions

action label category

not supported

Views

name title*

not supported

Purchases and Attributes are not supported.

(*) The title template is used by Google Tag Manage only.

General structure in tracking_config.json

The tracking service key name in "tracking_config.json" is: "google_analytics"

General structure


Event Configuration

Actions

Google Analytics 4 / Google Tag Manager supports action events.

Action event
Example


Views

Google Analytics 4 / Google Tag Manager supports view events.

Action event
Example Google Analytics 4
Example Google Tag Manager


Purchases

Google Analytics 4 / Google Tag Manager does not support purchase events.

Attributes

Google Analytics 4 / Google Tag Manager does not support attributes.

Additional supported functionality

No additional functionality is currently supported.

How to configure

Native Purple App

Enable SDK

Google Analytics does not provide a standalone native integration. To use Google Analytics in your native apps, you must do so through Firebase .

Apple privacy / ATT

Since there is no native SDK available in the apps, there is no ATT-controlled behaviour.

Consent Management

Since there is no native SDK available in the apps, there is no CMP-controlled behaviour.

Web integration

Deprecated configuration

Deprecated configuration of Google Analytics 4 for Web. This configuration will be removed soon. 

Starting with PXP 3.7.0, the configuration of Google Analytics 4 is preferably done via "experience.config.json", as described in the "Enable SDK" section below.

Settings location

"Your app" => "Consent/Push/Analytics" => "Analytics (General/Web)"

Setting

Description

Enable Google Analytics 4

To enable the Google Analytics 4 SDK on the web, activate this checkbox.

Google Analytics 4 Measurement ID

The measurement id.

Have a look at our screenshot based setup guide: Set Up Google Analytics 4

Enable SDK

Google Analytics is not explicitly enabled. If a valid configuration of Google Analytics is present in the "experience.config.json", the SDK is integrated into the HTML document. This can be either done as Google Analytics 4 or as Google Tag Manager. The corresponding configurations differ as follows:

Structure in experience.config.json

Google Analytics 4
Google Tag Manager


Google Analytics 4

Setting

Description

measurementId

Measurement id of your connected GA4.

Google Tag Manager

Setting

Description

useTagManager

Enables the Google Tag Manager instead of Google Analytics 4

addNoScript

Add the noscript iframe element to the body-element.

Default is "false"

containerId

The id of the connected container.

Consent management

If you use one of the CMPs supported by Purple, you must specify the CMP-specific vendor id for Google Analytics, which you can get from your CMP frontend. Additionally, the IAB vendor id for Google Analytics can also be added.

Structure in experience.config.json

Google Aanalytics with consent
Google Tag Manager with consent


Setting

Description

vendorId

The vendor ID managed by your CMP.

iabVendorId

The vendor ID managed by IAB.