Money Script: convert links to the brand’s site into Travelpayouts affiliate links

So, your website already has links to the sites of travel brands, such as, Tripadvisor, GetYourGuide, and others, but you want to convert them into Travelpayouts affiliate links to start earning with us? You can quickly do that with the Travelpayouts Money Script. 

What is the Travelpayouts Money Script

The Travelpayouts Money Script is a piece of JavaScript code, such as code from Google Analytics, that you add to your site to receive detailed statistics. It converts existing links to brands’ websites into Travelpayouts links with your ID. Generating and replacing links manually can be time-consuming and complicated. Money Script solves this problem automatically in a matter of minutes. Here are some cases in which Travelpayouts Money Script can help you.

Your site has non-partner links to brands’ sites

Let’s say you have a website with travel content containing generic links to a brand’s offers, such as: When your readers click on these links, you don't earn anything.

Now, you want to start monetizing your content. If you connect to the Partner Program through Travelpayouts and add its Money Script to your site, it will redirect your users to partner links. So, you will earn on each sale made via this URL.

You’re already working with a brand partner program, but want to continue to do so through Travelpayouts

Let’s say you’re already working with a brand's direct affiliate program, or you partner with that brand on another network and use its links, but you want to start working with that brand through the Travelpayouts partnership platform.

In this case, Money Script will help you automatically replace such affiliate links (for example, links like with Travelpayouts links (if you connect to this partner program through Travelpayouts). This way, you’ll see clicks, bookings, and more in your Travelpayouts reports and receive a payout from the platform.

What is needed to use Money Script

To use Money Script, you should:

  • Have a website and access to edit its code.
  • Have a minimal understanding of HTML.
  • Sign up for the Travelpayouts partnership platform.
  • Connect to the partner programs in Travelpayouts with which you want to earn on this platform.

Important! Not all links can be replaced with Money Script. It depends on the program. You can find the list of all programs supporting Money Script in the List of programs section below.

How to Place and Set Up Money Script on Your Website

  1. Connect to those programs whose links you want to convert into Travelpayouts partner links. You can find the catalog in the Programs section of your account.
  2. Copy the code below (it’s a Money Script code):
<script async="" src=",Z" type="text/javascript"></script>
  1. If you use WordPress (or another constructor, where the <head> … </head> section is configured separately from the content), place this code before the closing tag — </head>.

In all other cases, you can use Google Tag Manager and add a script through this tool. 

  1. Replace XXXXXX in the “marker” parameter in this code with your ID, which can be found in your Travelpayouts account in the upper right corner.

  1. (optional) Replace YY,ZZ in the “exclude” parameter in this code with the ID of the programs, the links to which the script shouldn’t change. This option allows you to exclude programs that you work with directly or in the other partnership networks. You can get the ID of the program from its URL. For example,, where 84 is the ID of the program. Don’t leave a space between the IDs of the partner programs.

If you don't need the script anymore, just delete the code from the <head> tag.

When working with the Travelpayouts Money Script, keep the following in mind:

  1. Money Script only replaces links to the programs which you connected in Travelpayouts. Before using this tool, make sure to connect to the specific partner programs.
  2. When you replace links with affiliate links, they will not change in the article itself. This means that they will still look the same for the users.
  3. If you used a link shortener or other tool to hide links to third-party websites, the script will not be able to process them. The behavior of such links will remain unchanged.

How to make sure everything is working properly

You can check the script before adding it to the website code by executing the command indicated below once in the browser console.

var script = document.createElement('script');
script.onload = function() {
 alert("Script loaded and ready");
script.src =

If the script works correctly, you’ll see a message like this in your browser.

After reloading the page, everything will return to the way it was.

Also, you can follow new links in your posts and check out the statistics in your Travelpayouts account. The values in the table will change with each click-through after a few minutes.

List of programs supporting Money Script

Money Script can replace links only for the brands from the list below. Remember that you need to connect to the program before using Money Script.

  • 12Go
  • Agoda
  • AirHelp
  • AutoEurope (US, CA)
  • Aviasales
  • Big Bus Tours
  • Busbud
  • Discover Cars
  • Drimsim
  • EKTA
  • Flixbus US
  • GetYourGuide
  • Go City
  • HolidayTaxis
  • Hostelworld
  • Hotellook
  • Insubuy
  • KiwiTaxi
  • Klook
  • Omio
  • OYO
  • Rail Europe
  • TicketNetwork
  • Tiqets
  • Trainline
  • Viator
  • VisitorsCoverage
  • Vrbo

Tips for using Travelpayouts Money Script to earn more

Connect to more appropriate partner programs

Maybe you've been earning in affiliate marketing for a long time, but used one or two programs, and have given non-partner links to other travel services. In this case, you can connect to other partner programs as needed in order to turn as many links as possible into affiliate links and earn more.

Use Travelpayouts Money Script if you have user-generated content

Pay attention to the user-generated content on your site. For example, if you have a blog where travelers share their travel reviews, you can monetize any link in their content.