AMP Tracking in Analytics: set 'useAmpClientId': true

Gerhard5000
Silver Contributor
Silver Contributor Gerhard5000

Hi there,

as described here https://support.google.com/analytics/answer/7486764?hl=en

we would like to track users coming from an AMP page with the same cid.

Do you know how to add this part {'useAmpClientId': true} into the template of the google analytics tag?

Thank you very much.

Best regards,

Jerrit 

2 REPLIES 2

AMP Tracking in Analytics: set 'useAmpClientId': true

Gerhard5000
Silver Contributor
Silver Contributor Gerhard5000

Any idea here?

AMP Tracking in Analytics: set 'useAmpClientId': true

Tealium Employee

Hi Gerhard5000,

As this is a new option and not available on the tag config screen, I would recommend modifying the tag template for google analytics in the u.data object; adding in the line of code:

if analytics.js, use : 'useAmpClientId': true

if gtag.js, use: 'use_amp_client_id': true

Also, I will submit a product enhancement request to get this added as an option in the Tag Configuration for Google Analytics.

Just to add some extra information about the setup and limitations with using this feature: https://support.google.com/analytics/answer/7486764?hl=en