How to enable GA enhanced link attribution in GTM
Enabling enhanced link attribution in Google Analytics will give you a clearer picture of which links on a given page are clicked. If you have are linking to another page, with links in the header and the footer, enhanced link attribution will track clicks of the header and footer links independently.
Google Analytics doesn't give clear details of how to set this up, here's what you need to to to enable GA enhanced link attribution with Google Tag Manager (GTM) or the standard javascript snippet.
- In Google Analytics Admin > Property Settings, enable enhanced link attribution
- With the traditional GA tracking snippet add the line ga('require', 'linkid'); as below
ga('create', 'UA-XXXXX-Y', 'auto'); ga('require', 'linkid'); ga('send', 'pageview');
- If you are using Google Tag Manager, (GTM),
- locate the variable for your GA tracking ID, then More Settings > Advanced Configuration > Enable Enhanced Link Attribution > True
That's it, good luck!