Gary Hainsworth

How To Track Clicks On A Link In Google Analytics

8th May 2020 Analytics, SEO Blog 3 minutes to read

How To Track Clicks On A Link In Google Analytics

Collecting data on various metrics across your site is fundamental, but many times we neglect to track the basic interactions on a site. It’s good to know how long a video was played, how many social shares a page has or how long a user spent reading your content, but how do they actually navigate through your site?

You can find some data through standard Google Analytics, but it’s much more useful to find out exactly which links get clicked with Google Tag Manager.

With Google Tag Manager

External Links

The focus in digital marketing is to keep users on your site, but external linking isn’t a bad thing. It helps greatly with user interactions and can do a great job of showing you what users want more information about when tracked – giving you further focus for your content and other marketing efforts.

Tracking all external clicks is an easy tag to set up and is recommended to be tracking as soon as possible. All you need to do is create an event which fires on link clicks that don’t contain your domain name. This can send the target URL through as an event into Analytics.

Setting up the Trigger

  1. Create the trigger and name it ‘Outbound Link Clicks’ or something similar
  2. Set the Trigger Type to ‘Click – Just Links’
  3. Set to Trigger firing on ‘Some Link Clicks’
  4. Use the built-in variable ‘Click URL’ and set as ‘does not contain’ and enter your domain name

Setting up the Tag

  1. Create the Tag and name it ‘Event – Outbound Link Click’, or whatever suits your naming convention
  2. Select Google Analytics in the Tag Type
  3. Set to ‘Event’
  4. Select appropriate Category, Action and Label as below:
    1. Category – External Link
    2. Action – Link Click
    3. Label – {{Click URL}}

All set!

Internal Links

Tracking internal links gives great insight for user experience purposes and when used with other metrics (scroll tracking, time on page, etc.), it can create a good user experience report without the need for extra tools.

The setup is similar to the external links above.

Setting up the Trigger

  1. Create the trigger and name it ‘Internal Link Clicks’ or something similar
  2. Set the Trigger Type to ‘Click – Just Links’
  3. Set to Trigger firing on ‘Some Link Clicks’
  4. Use the built-in variable ‘Click URL’ and set as ‘contains’ and enter your domain name

Setting up the Tag

  1. Create the Tag and name it ‘Event – Internal Link Click’, or whatever suits your naming convention
  2. Select Google Analytics in the Tag Type
  3. Set to ‘Event’
  4. Select appropriate Category, Action and Label as below:
    1. Category – External Link
    2. Action – Link Click
    3. Label – {{Click URL}}
  5. Extra step – Set up the ‘Value’ field

What to use for the Value field?

This is where you can add great extra value to these events. You can feed through any number of strings into the Value field, so make the most of it depending on your site setup.

It can be a simple {{Click Text}} field to show what the link says. With this you can conclude if it was a menu link, a blog post link, sale item, etc. This does leave them open to interpretation though, particularly if you have multiple links to the same page, such as top categories on an ecommerce site.

Using the {{Click Element}} variable can isolate it down to the element type. This can help you see if the clicks are in the header, body content or even the footer. This isn’t always 100% accurate, but it can give a clearer picture.

Using a custom variable can be complicated, but it gives the best results. This can be done from a Google Sheet reference table or through naming conventions across the html code. Tracking like this is best worked out on an individual basis and will often require development work as well.

Without Google Tag Manager

This isn’t recommended, but the best place to start is here.

We can help you plan out all of your site tracking needs from raw user figures through to micro-conversions, so get in touch today.

Share this post

Gary Hainsworth

Senior Organic Data Specialist

Gary is our technical SEO specialist and boasts more than 10 years’ experience in the industry. With in-depth knowledge on site migrations and all aspects of technical SEO, he’s a valuable asset to our team. Gary’s worked with the likes of the V&A, Warburtons, the NHS and the Lake District National Park. He has a passion for guitars too, be that playing them, modifying them or even building them. Gary has appeared in Startups Magazine, Portsmouth News and Southampton.gov.uk.

What do you think?

aspect-ratio
Kelly-Anne Crean

SEO and Internal Links: Common Mistakes to Avoid

Kelly-Anne Crean
1st Jun 2023
SEO Blog
aspect-ratio
Stacey Cavagnetto

How to Do PR for Small Businesses

Stacey Cavagnetto
25th May 2023
Digital PR Blog

Digital Ideas Monthly

Sign up now and get our free monthly email. It’s filled with our favourite pieces of the news from the industry, SEO, PPC, Social Media and more. And, don’t forget - it’s free, so why haven’t you signed up already?

Free Digital Marketing Audit

Are you a UK business that needs some expert help to uncover what’s holding your digital marketing back? Let us show you for free!

Questions?

Call us on 0330 353 0300, email info@koozai.com or fill out our Contact Form.

Map of Hampshire Digital Marketing Agency
Hampshire Digital Marketing Agency
Merlin House 4 Meteor Way Lee-on-the-Solent, PO13 9FU, UK
Map of Lancashire Digital Marketing Agency
Lancashire Digital Marketing Agency
Cotton Court Business Centre Church Street, Preston Lancashire, PR1 3BY, UK
Map of London Digital Marketing Agency
London Digital Marketing Agency
Albert House 256 - 260 Old Street London, EC1V 9DD, UK

Unlike 08 numbers, 03 numbers cost the same to call as geographic landline numbers (starting 01 and 02), even from a mobile phone. They are also normally included in your inclusive call minutes. Please note we may record some calls.

Circle Cross