Vitaliy Hayda
Vitaliy Hayda

Reputation: 113

Track button views and clicks as events in google analytics

I am trying to place a button that will be inside email and I want to track button views and clicks (Google Analytics events). Can you tell me if that is possible and how to do that?

Upvotes: 1

Views: 435

Answers (2)

Trần Duy Ninh
Trần Duy Ninh

Reputation: 1

This is able to track button views by using Measurement protocol, and using UTM tagging to track sessions come from this button (but not actual clicks).

Upvotes: 0

Philip Walton
Philip Walton

Reputation: 30461

You can't technically track a button click from an email, but what you can do is control where the button links to.

If you set the button's URL to point to your servers, you can intercept the link, send a hit to Google Analytics using the Measurement Protocol, and then redirect the user to where the button was originally pointing.

Alternatively, you could append custom campaign parameters to the end of the URL (utm_medium, utm_source, etc.). This would allow you to know what source the hit came from. Here's some information on custom campaigns:
https://support.google.com/analytics/answer/1033863?hl=en

Upvotes: 4

Related Questions