Best Tools for Tracking Affiliate Links on Your Website

Natalia Tsvetkova Natalia Tsvetkova
Updated:
Reading time:  9  min.
25714
2

Affiliate marketing is an incredibly competitive industry. That is why it is vital to leverage the best marketing tools if you want to boost your revenue and succeed as an affiliate. Tracking the general performance of your campaigns, your affiliate links in particular, is of the utmost importance as it allows you to assess the power and effectiveness of your campaigns. So, we’ve prepared a guide on how to track your affiliate links with the help of the best tools on the market.

best-tools-tracking-affiliate-links

What Are Affiliate Links?

Before we answer this question, let’s define the term affiliate marketing. Affiliate marketing is an online tactic based on the revenue-sharing principle which presupposes that a merchant website pays affiliate websites a commission for driving traffic to it.

Affiliate marketing is a win-win scenario both for brands and for partners. It allows brands to reach customers they wouldn’t reach on their own, and partners are provided with ample opportunities to boost their revenue.

For example, Travelpayouts is a travel partnership platform that connects creators, travelers, and travel brands: 

  • Creators recommend the travel brands they love to their audience and are rewarded for their efforts.
  • Travelers book their perfect trips at the best prices and explore fascinating places (both near and far).
  • Travel brands connect with influencers and content creators to extend their reach and increase sales.

Travelpayouts helps people to do what they like. Some travel cheaper and more often, while others earn on their hobbies. Take a couple of minutes to join the Travelpayouts and start integrating affiliate links on your website to earn with well-known brands, such as Booking.com, TripAdvisor, Kiwi.com, etc.

Join the Travelpayouts partnership platform

Streamline your travel blog's financial success.

Join today
480,000 partners already trust us
$63M+ total paid since 2011
100+ travel brands

The term “affiliate link” is a key term in affiliate marketing. It denotes a special URL that contains the ID or the username of the partner. It is used for the brand to track affiliate performance and all traffic the partner sends to the brand’s site as a part of the travel affiliate program. You are provided with an affiliate link when you sign up your partner membership.

Every affiliate link contains the original domain followed by the ID. You can find your ID on the dashboard. For instance, the affiliate link to the flight ticket in the WayAway aggregator, generated on the Travelpayouts partnership platform will have the following layout: https://tp.media/r?marker=202631.sidebar…, where “http://tp.media/” stands for the original domain, “202631” is your ID, and “sidebar” is an additional marker (sub id)

Some networks allow partners to shorten links to hide technical parameters in URLs. In this case, the shortened affiliate link of the WayAway program is https://wayaway.tp.st/…, where “https://wayaway/” stands for the brand name and “tp.st” are second and top-level domains.

The additional marker (sub id) is a parameter that allows for the tracking of sales separately for each traffic source/promo material. Learn more how to use it from the video below:

How to create travel affiliate links to earn revenue

Why Is Link Tracking Important for Affiliate Marketing?

Tracking is one of the most crucial things in affiliate marketing for several reasons.

First, it’s the backbone of the strategy, because tracking affiliate links allows brands to track sales back to the partner and pay rewards. Tracking helps identify top partners and reward them accordingly.

Second, tracking is invaluable for identifying the most profitable links and the most converting pages. Making conversions is the prime goal of affiliate marketing, and the process involves visitors completing desired actions on a site, for example, making a purchase, completing a form, or signing up for emails. Understanding which promotional methods drive more conversions is essential for improving your performance and increasing your revenue, no matter whether you are a brand or a partner.

However, whether conversions occur or not, both brands and partners can still benefit from tracking affiliate links because it helps them to understand their campaign’s strengths and weaknesses and improves their products or campaigns.

How to Keep Track of Your Affiliate Links

As we’ve already mentioned, tracking is extremely important for affiliate marketing, but how do you track affiliate links? There are two common ways to track, which allow you to assess how successful your affiliate campaigns are.

Client-Based Tracking

Client-based link tracking for affiliates implies that when a visitor of a website clicks on a link, which leads them to a landing page, the ID is stored on their browser within a text file, known as a cookie. The cookie lifetime period depends on the brand; some cookies can be deleted automatically when a user closes the browser or after a period of inactivity, while others expire in, 30 or 60 days, for instance.

If a customer completes the desired action on the brand’s page, a small piece of code, known as a conversion pixel, loads up and reads the cookie information (transaction ID). The information is further sent to the system for tracking conversions, and the conversion is recorded for the proper partner. Eventually, the reward is paid to the affiliate.

Note that a browser cookie can be tracked only within the specific browser, so if a customer opens a different browser and makes a conversion, it will not be tracked.

Server-To-Server Tracking

This type of tracking is also called cookieless tracking as it is completely independent of cookies, and nothing needs to be placed on the user’s computer to store information. Instead, the information associated with the user and the partner is stored on the brand’s server, and a unique identifier called the transaction ID is attached to it.

So, when a user completes a conversion after clicking on a unique tracking link, the system sends the postback with the transaction ID to the conversion tracking system.

This tracking type is often considered more accurate and reliable as no conversion is lost when the user has cookies disabled on the browser, and the brand is responsible for storing the unique identifier. However, to implement this tracking type, the brand has to support this kind of tracking on their back-end which is more technically complex in comparison to client-based tracking.

The Best Tools to Track Affiliate Links

We’ve already pointed out that you need to leverage tracking links properly if you want to boost your revenue and succeed as an affiliate marketer. Nowadays, the internet is swarming with affiliate links tracking software, which promises to boost your conversions.

However, not all affiliate links tracker programs are accurate and reliable enough, so we would like to tell you how to track your affiliate links by harnessing the functionality and usability of Google Analytics and Google Tag Manager tools.

Google Analytics

Google Analytics is one of the best web analytics platforms available on the market. It helps you collect data, and track and analyze your entire website traffic, so affiliate tracking is just one of the metric types Google Analytics tracks.

So, you’ve decided to start tracking affiliate links in Google Analytics. What do you have to do? We’ve described how to track affiliate links in Google Analytics below.

  1. The first step is signing in to Google Analytics and setting up a property.  Properties are where you send data and set up reporting views. The whole process is described here.
  2. Creating a property generates a tracking ID (shown below)in which UA-XXXXX-Y is your personal tracking code.
<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-132808825-1"></script>
<script>
  window.dataLayer = window.dataLayer || [];
  function gtag(){dataLayer.push(arguments);}
  gtag('js', new Date());
 
  gtag('config', 'UA-XXXXX-Y');
</script>

Make sure that this code is installed, even if your property has already been added to Google Analytics, as the script we are going to describe below works exclusively with it.

  1.   Place the tracking code on the pages you would like to analyze.

How to track outbound links in Google Analytics

If you want to track inbound links, you can simply place your personal tracking code into your site code. If you want to track outbound links, you have to copy and paste this code as the first item into the <HEAD> of every web page that you want to track.

<script>
var trackOutboundLink = function(url) {
  gtag('event', 'click', {
    'event_category': 'outbound',
    'event_label': url,
    'transport_type': 'beacon',
    'event_callback': function(){document.location = url;}
  });
}
</script>

You’ll also need to add (or modify) the onclick attribute to the links you are going to track. The following example can be used as a model for your own links:

<a href="http://www.example.com" onclick="trackOutboundLink('http://www.example.com');return false;">Check out example.com</a>

How can you check that the tracking is functioning correctly?

  1. Click on the Real Time tab in your Google Analytics account
  2. Click on the Events tab
  3. Click on several links on your website
  4. Return to Google Analytics and see if there are any new events listed

Note: Universal Google Analytics will stop processing date on July 1, 2023. Instead, the company introduces Google Analytics 4 as the next generation analytics tool. For more information, visit the official website.

Google Tag Manager

Google Tag Manager (GTM) is a tag management system which aims to efficiently update and add website tags. Tags are code fragments that measure traffic and visitor behavior. GTM provides users with ample opportunities to safely and easily deploy analytics and measurement tag configurations in their projects.

While Google Analytics aims at generating reports about your website, the main purpose of GTM is to manage various tags like Google Analytics, Google Webmaster/Search Console, Facebook Pixel code, Adwords Remarketing code or any other third-party codes.

With GTM integrated on your website, you can delete all the tags and scripts you need from your site, add them to your Google Tag Manager dashboard and substitute them on your site with one GTM script, which will work on behalf of all of them. So, GTM doesn’t replace Google Analytics, but it helps users easily add Google Analytics tracking codes (tags) to your website, deploy GA event code snippets and define rules, when each GA event must fire.

Google Tag Manager can also be extremely valuable for affiliate marketing, as it allows affiliates to set up event tracking to track outbound link clicks from their websites and it sends all the data to Google Analytics.

Let’s have a look at the affiliate link-tracking algorithm with the help of Google Track Manager.

  1. Create a GTM account. A new container is created by default and you can create additional containers.
  2. After the window with the Google Tag Manager appears, copy the code and paste it to every page of your website as high in the header of the page as possible. The next step is to paste the code after the opening <body> tag.
Google Tag Manager
  1. Activate Built-in Variables by clicking on the Variables tab in your Workspace and then click on the Configure button, which will appear. Then tick the Click URL and Click Text variables in the pop-up window.
Activate Built-in Variables
  1. Create a Google Analytics ID as User-defined variable by clicking the New button in the Variables menu.
Create a Google Analytics ID
  1. Name the variable
Name the Variable
  1. Choose the variable type by clicking Google Analytics settings in the Variable types pop-up window.
Choose the variable type by clicking Google Analytics settings in the Variable
  1. Type in the Tracking ID from Google Analytics ( UA-XXXXX-Y)  which can be found in your Google Analytics account:  Administrator  > Property Settings.
Administrator > Property Settings
  1. Set up link tracking via GTM. To do this, delete The Google Analytics ID tracker from your website, create a new tag in GTM by clicking on the Tags tab and choosing the Google Analytics – Universal Analytics tag type.
Choose type
  1. Then, in the Tag configuration section, choose Pageview as your tracking type and the variable you’ve created earlier as your Google Analytics setting. Choose the All pages trigger in the Triggering section and then save the tag.
Settings
  1. Create a trigger for tracking outbound links. In order to do this, click on the Triggers tab and then click the New button in the pop-up window. You can name the trigger “Outbound link click”.
Outbound link click
  1. Select Just Clicks as your trigger type and choose your trigger to fire on Some Link Clicks. Set the conditions for firing this trigger by choosing Click URL, doesn’t contain and type in your website or blog URL. These parameters are essential as you will track only outbound links with this trigger. Then save the trigger settings.
Configuration
  1. Create a tag for tracking outbound links. The tag will load when a visitor clicks on an outbound link. Create a new tag of the Google Analytics – Universal Analytics type, the variable and the trigger Outbound link click you’ve created earlier. Choose Event as your track type, and the following event tracking parameters from the drop-down menu:
  • Category: Outbound link click
  • Action: {{Click URL}}
  • Label: {{Page URL}}
  • Non Interaction Hit: False

Finally, save the tag.

Save the tag
  1. To make sure that everything functions correctly, you have to choose Real-time Reports in Google Analytics first, and then choose Events in the drop-down menu. Click on several links on your website, then go back to Google Analytics and see if there are any new events.

Managing Links

While tracking affiliate links is essential for increasing your conversions, managing numerous affiliate links on your website is not any less important. Sooner or later the process of managing multiple links manually becomes almost impossible even for small sites.

A viable solution to this problem is using a link management system to fix the links via a redirect. Such tools allow you to replace a target URL in just a few clicks. This article describes and reviews the most important and effective tools serving this purpose.

It’s also important to check your content for invalid links, including those that contain typos or lead to errors. To avoid doing this manually, install LinkSwitcher. This tool analyzes URLs on your webpages and displays any invalid links in your Travelpayouts account. Learn more about LinkSwitcher in our article.

Should I Track Affiliate Links in 2023?

You definitely should, as the competition in the affiliate marketing industry is getting more and more intense, and partners have to redouble their efforts to stay afloat. Tracking links for affiliate campaigns is a proven way to boost your programs’ performance and optimize your marketing strategies. You should choose the best way to track affiliate links from the variety of tracking tools on the market and harness it properly to maximize your earnings.

This free guide for travel publishers will help you use links, widgets, and banners to most of the traffic you have.

Download