Follow me on LinkedIn - AI, GA4, BigQuery

External links (also known as ‘Outbound links’) are links to other websites from your website.

An external link is a URL that, when clicked, takes a user from one web page to another web page, and both the source and destination web pages are hosted on different websites/domains.

For example, a link to your LinkedIn profile from your ‘About Us’ page is an external link.

Introduction to GA4 outbound link/click tracking.

Through the GA4 ‘outbound clicks’ tracking feature, you can track clicks on external links in your GA4 property without any additional code or tagging.

Once you have enabled the ‘Outbound clicks’ tracking feature under ‘Enhanced Measurement’ in your GA4 property, GA4 automatically start tracking clicks on external links (i.e. outbound clicks):

Once you have enabled the ‘Outbound clicks tracking feature

Note: Outbound link tracking is also known as ‘exit tracking’.

Understanding the ‘click’ event.

Once you have enabled the ‘Outbound clicks’ tracking feature under ‘Enhanced Measurement’ in your GA4 property, whenever a user clicks on an external link on your website, GA4 fires an event called ‘click’.

You can see the ‘click’ event in your GA4 property via the ‘Events’ report:

the ‘Events report

You should check how the ‘click’ events are being recorded in the GA4 BigQuery data table and what event parameters are being passed along with this event type.

click event in ga4 bigquery data table

Take a close look at the various event parameters which are sent along with the ‘click’ events:

  1. ga_session_id
  2. page_title
  3. page_referrer
  4. page_location
  5. link_url
  6. ga_session_number
  7. batch_ordering_id
  8. outbound
  9. link_classes
  10. engagement_time_msec
  11. ignore_referrer
  12. session_engaged
  13. content_group
  14. engaged_session_event
  15. batch_page_id
  16. link_domain

While creating a text prompt to generate SQL, we will refer to these event parameters (esp, ‘link_url’ and ‘page_location’).