Blog

+ Free advice and other musings

How to See What Outbound Link Was Clicked in GA4

by | Apr 9, 2024 | Google Analytics

If you have outbound click tracking enabled (Admin > Data Streams > Enhanced measurement: toggle on click), then you may notice that the Standard Engagement > Events report is missing helpful information like what link was click.

You can view this information if you create a custom Explore report. But if you want quick access to that info in the Standard report then you need to register “link_url” as a custom dimension.

In the left sidebar, go to Admin > Custom Definitions > Custom Dimensions and click Create Custom Dimensions.

Enter the below settings:

Save the dimension. In a day or so, you will see the URLs of outbound clicks in the Standard report Engagement > Events > Click.

Why is Link Text missing? For some reason, this is not included in GA4’s enhanced measurement tracking for outbound clicks. If that info is important to you, then your best option is to turn off click tracking (Admin > Data Streams > Enhanced measurement: toggle off click) and instead use Google Tag Manager (GTM) to track events.

Analytics Mania has a great post on how to create your own outbound click tracking with GTM. With this setup, you can track link text, link url, link domain, and any other related parameter.

Note that setting up the link_domain parameter requires an additional step to track the Click Hostname (or link domain).

Click Hostname is not a built-in variable.

Go to Variables. Scroll down to User-defined variables. Click New. From there, select Auto-event variable. Set Variable Type as Element URL and Component Type as Hostname.

You can then add link_domain to custom events. In the following case, I have used it when tracking outbound clicks specific to “ShopLocal” retailer links on an ecommerce site.

Final words on tracking outbound clicks:

  • GA4 does not automatically display link_url in the Standard report Engagement > Events > click. You have to add link_url as a custom dimension.
  • Alternatively you can turn off the click event in GA4 Admin > Data streams > Enhanced measurement and set up your own outbound link tracking via Google Tag Manager (GTM). In this case GTM does not have link_domain as a pre-defined (build-in) variable. You need to make a user-defined variable for link_domain that captures the hostname (aka domain) or the clicked link.

Happy tracking.

You may also like …

AMA | Ask Me Anything

AMA | Ask Me Anything

I had 3 great marketing questions posed to me last week and I thought I'd share my responses. Question 1: Is there a way to show the Full URL of pages being shown in GA4 Realtime reports? Unfortunately there is no way to modify the Realtime reports. What you see is...

read more
How to Track Marketing Campaigns in GA4

How to Track Marketing Campaigns in GA4

Holiday campaign tracking provides insights into what's working or not working. But you need to set it up. It's 5 weeks and 3 days until Black Friday, and even if your business is not located in America, this retail event kicks off the holiday shopping season around...

read more