
{"id":2476,"date":"2020-11-21T21:40:07","date_gmt":"2020-11-21T18:40:07","guid":{"rendered":"https:\/\/blog.travelpayouts.com\/en\/?p=2476"},"modified":"2022-07-18T17:15:20","modified_gmt":"2022-07-18T14:15:20","slug":"url-redirection-and-replacement","status":"publish","type":"post","link":"https:\/\/www.travelpayouts.com\/blog\/url-redirection-and-replacement\/","title":{"rendered":"How to set up an affiliate link redirects and replace links on WordPress"},"content":{"rendered":"<h2>The problem with affiliate links<\/h2>\nOver time, the number of the links on a site increases to an amount that could be hardly managed manually. The trouble begins with even small-scale projects when the replacement of the old links with new ones is required \u2014 for example, in the case of redirecting traffic from old links to new pages. Manual replacement is the backbreaking labor.\n\nIn addition to difficulties maintaining the links, a large number of external links can influence the search engines\u2019 treatment of your project. Converting links to inline tag &lt;nofollow&gt;\u00a0partially solves the problem with search engines but doesn\u2019t simplify the maintenance of the hundreds of links on your site.\n<h3>Solution<\/h3>\nThe fundamental solution to the problem is to use a link management system to fix the links via a redirect.\n\nWith tools for creating and managing links, you can replace a target URL in just a few clicks. In the end, the link in your article still has the same format <em>yourdomain.com\/link1<\/em>, but the user goes not to <em>Aviasales.com<\/em> as before,\u00a0but to <em>flights.Aviasales.com<\/em>, for example.\n\nThere are several ways to manage affiliate links. We have collected the most important ones below and reviewed them in detail.\n<h2>What is the redirection of links?<\/h2>\nRedirecting is referring users to another page. When clicking a link such as <em>yourdomain.com\/link1<\/em>, the user lands on the affiliate page \u2014 for example, <em>Aviasales.com<\/em>.\n\nRedirection is necessary not only for managing links in articles but also for eliminating doubling, 404 errors, and domain name slake. In the last case, you can save the site\u2019s position in SERP and traffic from the previous domain name.\n\nRedirect algorithms are very simple:\n<ol>\n \t<li>The user clicks a link.<\/li>\n \t<li>The server or browser processes the data.<\/li>\n \t<li>The user is automatically redirected to the defined link in cases where there is redirect.<\/li>\n<\/ol>\nThis process is automatic and instantaneous.\n<h3>Redirects 301, 302, 307<\/h3>\nTen HTTP codes for redirects exist, but only three of them are in demand. Let\u2019s look at their key points.\n<ul>\n \t<li>301: A constant redirect indicating that the transfer is permanent. This code usually means the site\u2019s redirected while moving to another domain.<\/li>\n \t<li>302: A temporary redirect. It indicates that the site move is temporary. This is perfect for the redirecting affiliate links.<\/li>\n \t<li>307: A Temporary redirect. The implementation of the code doesn\u2019t allow the query method (GET\/POST) to change. In practice, codes 307 and 302 are identical.<\/li>\n<\/ul>\n<h2>How to set up a link redirection<\/h2>\nRookies could hardly deal with putting redirects into effect. That\u2019s why we have reviewed the basic methods for redirecting links.\n<h3>Services for truncating links<\/h3>\nThese services help <a href=\"https:\/\/blog.replug.io\/retargeting-mistakes\/\" target=\"_blank\" rel=\"noopener\">redirect links<\/a> without changing your settings or installing software. You can just use the services\u2019 web-based versions:\n<ul>\n \t<li><a href=\"https:\/\/goo.gl\/\" target=\"_blank\" rel=\"noopener noreferrer\">https:\/\/goo.gl\/<\/a> (works up to March 30, 2019)<\/li>\n \t<li><a href=\"https:\/\/u.to\/\" target=\"_blank\" rel=\"noopener noreferrer\">https:\/\/u.to\/<\/a><\/li>\n \t<li><a href=\"https:\/\/bitly.com\/\" target=\"_blank\" rel=\"noopener noreferrer\">https:\/\/bitly.com\/<\/a><\/li>\n<\/ul>\nThe examples above are simple services for shortening links. These redirects don\u2019t solve all your problems but do allow you to package the links in the same format and learn more statistics.\n<p class=\"p1\">If you\u2019re working with programs through <a href=\"https:\/\/www.travelpayouts.com\/en\/\"><span class=\"s1\">Travelpayouts<\/span><\/a> and your goal is to create beautiful, short affiliate links, it\u2019s not necessary to use third-party services. You can create a short URL without leaving your Travelpayouts\u2019 account. Simply open the \u00abLink Generator\u00bb tool on the page of the selected program and fill in the required fields. The generator will return a short version of the affiliate link with the name of the brand included.<\/p>\n\n<h3>HTML, JS, and PHP Scripts<\/h3>\nRedirection that is done with the aid of PHP scripts puts additional strain on the server. However, it is preferable when you have a great number of pages. This kind of redirection is performed on the server level.\n\nA redirect using JavaScript operates on the browser level. The full load in the browser is required to make it work, which is why this method is slower than a PHP redirect. It is sometimes used for redirections with a delay. Also, JS redirect doesn\u2019t work unless you switch on a JavaScript function.\n\nRedirection via an HTML code is similar to JS and operates on the browser level, so it proceeds slower than redirects on the server level.\n<h3>WordPress plugins<\/h3>\nIf the website is based on WordPress, then it is better to use third-party plugins. They help to shorten the link and to create the link on your domain, as well as manage redirects and collect statistics.\n\nBelow we look at each of the redirects\u2019 methods and give the valid sample.\n<h2>The top three URL shorteners for shortening long links<\/h2>\n<ol>\n \t<li>Goo.gl<\/li>\n<\/ol>\n<div class=\"wp-block-image aligncenter size-full wp-image-2480\">\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;69f13e7de2ed7&quot;}\" data-wp-interactive=\"core\/image\" class=\"wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on-async--click=\"actions.showLightbox\" data-wp-on-async--load=\"callbacks.setButtonStyles\" data-wp-on-async-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/google-url.jpg\" alt=\"https:\/\/goo.gl\/\" class=\"aligncenter size-full wp-image-2480\" width=\"1838\" height=\"858\" srcset=\"https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/google-url.jpg 1838w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/google-url-1536x717.jpg 1536w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/google-url-300x140.jpg 300w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/google-url-768x359.jpg 768w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/google-url-1024x478.jpg 1024w\" sizes=\"auto, (max-width: 1838px) 100vw, 1838px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\taria-label=\"Enlarge\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on-async--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.imageButtonRight\"\n\t\t\tdata-wp-style--top=\"state.imageButtonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure><\/div>\n\n<a href=\"https:\/\/goo.gl\/\" target=\"_blank\" rel=\"noopener noreferrer\">Google\u2019s service for link reduction<\/a> has always demonstrated a pattern of consistent quality. You can proceed with any actions in just a few clicks. The interface is intuitive, easy to use, and minimalistic. You should authorize the statistics, where you can learn\n<ul>\n \t<li>The number of hops<\/li>\n \t<li>Citations for the links on the web<\/li>\n \t<li>The map of popularity in different countries<\/li>\n \t<li>Platforms and browsers viewer use the most often<\/li>\n<\/ul>\nUnfortunately, as of April 13, 2018, only old users can use this service. Google will stop running this service on March 30, 2019.\n<ol start=\"2\">\n \t<li>Bitly.com<\/li>\n<\/ol>\n<div class=\"wp-block-image aligncenter size-full wp-image-2481\">\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;69f13e7de308e&quot;}\" data-wp-interactive=\"core\/image\" class=\"wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on-async--click=\"actions.showLightbox\" data-wp-on-async--load=\"callbacks.setButtonStyles\" data-wp-on-async-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/bitly.jpg\" alt=\"Bitly.com\" class=\"aligncenter size-full wp-image-2481\" width=\"1487\" height=\"703\" srcset=\"https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/bitly.jpg 1487w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/bitly-300x142.jpg 300w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/bitly-768x363.jpg 768w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/bitly-1024x484.jpg 1024w\" sizes=\"auto, (max-width: 1487px) 100vw, 1487px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\taria-label=\"Enlarge\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on-async--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.imageButtonRight\"\n\t\t\tdata-wp-style--top=\"state.imageButtonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure><\/div>\n\n<a href=\"https:\/\/bitly.com\/\" target=\"_blank\" rel=\"noopener\">Bitly<\/a> is one of the leading services for link reduction. You can name short links and see the detailed statistics. The service is free, but a paid version is available. The paid version widens the functionality sufficiently. With it, you will get\n<ul>\n \t<li>Detailed analyses<\/li>\n \t<li>A link builder<\/li>\n \t<li>Flexible corporative settings<\/li>\n \t<li>Extensive technical support<\/li>\n \t<li>A personal manager<\/li>\n<\/ul>\n<ol start=\"3\">\n \t<li>U.to<\/li>\n<\/ol>\n<div class=\"wp-block-image aligncenter size-full wp-image-2482\">\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;69f13e7de3221&quot;}\" data-wp-interactive=\"core\/image\" class=\"wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on-async--click=\"actions.showLightbox\" data-wp-on-async--load=\"callbacks.setButtonStyles\" data-wp-on-async-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/u-to.jpg\" alt=\"U.to\" class=\"aligncenter size-full wp-image-2482\" width=\"1086\" height=\"577\" srcset=\"https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/u-to.jpg 1086w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/u-to-300x159.jpg 300w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/u-to-768x408.jpg 768w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/u-to-1024x544.jpg 1024w\" sizes=\"auto, (max-width: 1086px) 100vw, 1086px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\taria-label=\"Enlarge\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on-async--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.imageButtonRight\"\n\t\t\tdata-wp-style--top=\"state.imageButtonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure><\/div>\n\n<a href=\"https:\/\/u.to\/\" target=\"_blank\" rel=\"noopener noreferrer\">U.to<\/a> is a simple service with a minimal set of options. It allows you to create a very short link starting with u.to.\n\nThe service is available in seven languages. According to user reviews, this site is one of the most trusted services, always works always well, and hasn\u2019t had much downtime in the past.\n<h2>Popular plugins for WordPress<\/h2>\nDesign plugins offer a similar mechanism but include various extra functions. You will get a shortened link on your domain as a result. Plugins provide fast link redirection on WordPress and a convenient way to manage the links. For example, you can replace the target URL.\n<h3>Thirsty Affiliates Affiliate Link Manager<\/h3>\n\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;69f13e7de33ac&quot;}\" data-wp-interactive=\"core\/image\" class=\"wp-block-image alignnone size-full wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on-async--click=\"actions.showLightbox\" data-wp-on-async--load=\"callbacks.setButtonStyles\" data-wp-on-async-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/blog.travelpayouts.com\/wp-content\/uploads\/2018\/09\/ThirstyAffiliatesAffiliateLinkManager.jpg\" alt=\"Thirsty Affiliates Affiliate Link Manager\" class=\"alignnone size-full\" width=\"1587\" height=\"605\"\/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\taria-label=\"Enlarge\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on-async--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.imageButtonRight\"\n\t\t\tdata-wp-style--top=\"state.imageButtonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure>\n\n\n<a href=\"https:\/\/wordpress.org\/plugins\/thirstyaffiliates\/\" target=\"_blank\" rel=\"noopener\">Thirsty Affiliates Affiliate Link Manager<\/a> is a high-quality plugin claiming to be a helpful assistant for bloggers who <a href=\"https:\/\/travelpayouts.com\/blog\/25-best-affiliate-programs\/\" target=\"_blank\" rel=\"noopener noreferrer\">reap returns from affiliate programs<\/a>. Its 20,000 active downloads and good ratings prove the quality and popularity of the plugin. The users have mentioned the following facts in their reviews:\n<ul>\n \t<li>Easy to use due to the visual editor<\/li>\n \t<li>Increased experience with managing links<\/li>\n \t<li>Safe redirect via the 301, 302, and 307 codes<\/li>\n \t<li>Add images to the affiliate links<\/li>\n \t<li>Statistics and reports<\/li>\n<\/ul>\nA paid version (PRO version) for one, five, or any number of sites is available.\n<h3>Shortlinks by Pretty Links<\/h3>\n\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;69f13e7de3530&quot;}\" data-wp-interactive=\"core\/image\" class=\"wp-block-image alignnone size-full wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on-async--click=\"actions.showLightbox\" data-wp-on-async--load=\"callbacks.setButtonStyles\" data-wp-on-async-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/blog.travelpayouts.com\/wp-content\/uploads\/2018\/09\/pretty-links.jpg\" alt=\"Shortlinks by Pretty Links\" class=\"alignnone size-full\" width=\"1116\" height=\"376\"\/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\taria-label=\"Enlarge\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on-async--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.imageButtonRight\"\n\t\t\tdata-wp-style--top=\"state.imageButtonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure>\n\n\n<a href=\"https:\/\/wordpress.org\/plugins\/pretty-link\/\" target=\"_blank\" rel=\"noopener noreferrer\">Shortlinks by Pretty Links<\/a> is a multi-functional plugin for managing links on WordPress that has already collected 200,000 active installations. With the plugin, you can create your own links with the redirection to the target URL from your website\u2019s administrative panel. You can also manage the links that have been previously created. There is no need to know how to code to work with this service.\n\nThe paid version main options:\n<ul>\n \t<li>301, 302, and 307 redirects<\/li>\n \t<li>Link categorization<\/li>\n \t<li>Statistics graphics<\/li>\n \t<li>Data exporting in .csv format<\/li>\n<\/ul>\n<h3>How to install<\/h3>\nYou can download the archive from the official library or install the plugin via your website\u2019s <a href=\"https:\/\/yourdomain.ru\/wp-admin\/plugin-install.php\" target=\"_blank\" rel=\"noopener\">administrative panel<\/a>. Type the plugin\u2019s name in the search bar and click Install:\n\n<div class=\"wp-block-image aligncenter size-full wp-image-2484\">\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;69f13e7de36b9&quot;}\" data-wp-interactive=\"core\/image\" class=\"wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on-async--click=\"actions.showLightbox\" data-wp-on-async--load=\"callbacks.setButtonStyles\" data-wp-on-async-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/install.jpg\" alt=\"How to Install\" class=\"aligncenter size-full wp-image-2484\" width=\"1892\" height=\"809\" srcset=\"https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/install.jpg 1892w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/install-1536x657.jpg 1536w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/install-300x128.jpg 300w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/install-768x328.jpg 768w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/install-1024x438.jpg 1024w\" sizes=\"auto, (max-width: 1892px) 100vw, 1892px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\taria-label=\"Enlarge\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on-async--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.imageButtonRight\"\n\t\t\tdata-wp-style--top=\"state.imageButtonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure><\/div>\n\nA new block will appear in the administration menu after plugin activation:\n\n<div class=\"wp-block-image aligncenter size-full wp-image-2485\">\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;69f13e7de3848&quot;}\" data-wp-interactive=\"core\/image\" class=\"wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on-async--click=\"actions.showLightbox\" data-wp-on-async--load=\"callbacks.setButtonStyles\" data-wp-on-async-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/menu.jpg\" alt=\"Menu\" class=\"aligncenter size-full wp-image-2485\" width=\"1051\" height=\"800\" srcset=\"https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/menu.jpg 1051w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/menu-300x228.jpg 300w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/menu-768x585.jpg 768w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/menu-1024x779.jpg 1024w\" sizes=\"auto, (max-width: 1051px) 100vw, 1051px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\taria-label=\"Enlarge\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on-async--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.imageButtonRight\"\n\t\t\tdata-wp-style--top=\"state.imageButtonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure><\/div>\n<h3>Links creating<\/h3>\nHop to the &#8220;Add Link&#8221; section: https:\/\/yourdomain.com\/wp-admin\/admin.php?page=add-new-pretty-link. The editor will open. Set a short link and a target URL:\n\n<div class=\"wp-block-image aligncenter size-full wp-image-2486\">\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;69f13e7de39e4&quot;}\" data-wp-interactive=\"core\/image\" class=\"wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on-async--click=\"actions.showLightbox\" data-wp-on-async--load=\"callbacks.setButtonStyles\" data-wp-on-async-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/target-url.jpg\" alt=\"Links Creating\" class=\"aligncenter size-full wp-image-2486\" width=\"1870\" height=\"767\" srcset=\"https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/target-url.jpg 1870w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/target-url-1536x630.jpg 1536w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/target-url-300x123.jpg 300w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/target-url-768x315.jpg 768w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/target-url-1024x420.jpg 1024w\" sizes=\"auto, (max-width: 1870px) 100vw, 1870px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\taria-label=\"Enlarge\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on-async--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.imageButtonRight\"\n\t\t\tdata-wp-style--top=\"state.imageButtonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure><\/div>\n\nIn the redirection area, choose the basic parameters\u2014in this case, 302. Click Create at the bottom of the page to save the link.\n\nThen you can use the link \u2014 in this case, yourdomain.com\/avia \u2014 anywhere you want. The user will hop to the page you\u2019ve set after he clicks the link \u2014 https:\/\/search.Aviasales.com\/flights\/LON1312IST1\u00a01 in our example.\n<h3>Managing links<\/h3>\nAll the links are accumulated on the plugin\u2019s main page. Here you also see the basic statistics, such as the total number of clicks.\n\n<div class=\"wp-block-image aligncenter size-full wp-image-2487\">\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;69f13e7de3bbd&quot;}\" data-wp-interactive=\"core\/image\" class=\"wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on-async--click=\"actions.showLightbox\" data-wp-on-async--load=\"callbacks.setButtonStyles\" data-wp-on-async-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/managing.jpg\" alt=\"Managing Links\" class=\"aligncenter size-full wp-image-2487\" width=\"1909\" height=\"830\" srcset=\"https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/managing.jpg 1909w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/managing-1536x668.jpg 1536w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/managing-300x130.jpg 300w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/managing-768x334.jpg 768w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/managing-1024x445.jpg 1024w\" sizes=\"auto, (max-width: 1909px) 100vw, 1909px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\taria-label=\"Enlarge\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on-async--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.imageButtonRight\"\n\t\t\tdata-wp-style--top=\"state.imageButtonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure><\/div>\n\nYou can change your target URL as needed\u2014just choose the link you\u2019re interested in and set a new Target URL in the opened window. Then the previous link will lead you to a new page, and you don\u2019t have to replace the link on your site. On the Clicks page, more data on the clicks is available.\n\n<div class=\"wp-block-image aligncenter size-full wp-image-2488\">\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;69f13e7de3d4e&quot;}\" data-wp-interactive=\"core\/image\" class=\"wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on-async--click=\"actions.showLightbox\" data-wp-on-async--load=\"callbacks.setButtonStyles\" data-wp-on-async-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/report.jpg\" alt=\"Report\" class=\"aligncenter size-full wp-image-2488\" width=\"1480\" height=\"437\" srcset=\"https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/report.jpg 1480w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/report-300x89.jpg 300w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/report-768x227.jpg 768w, https:\/\/www.travelpayouts.com\/blog\/wp-content\/uploads\/2018\/11\/report-1024x302.jpg 1024w\" sizes=\"auto, (max-width: 1480px) 100vw, 1480px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\taria-label=\"Enlarge\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on-async--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.imageButtonRight\"\n\t\t\tdata-wp-style--top=\"state.imageButtonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure><\/div>\n<h3>Expanded opportunities<\/h3>\nEverything that is outlined above is available in the free version. The plugin\u2019s paid version, Pretty Link Pro, is also available. The following functions are available with the paid version:\n<ul>\n \t<li>Auto-replacement of links on the website<\/li>\n \t<li>Auto-deployment of links for the specified words<\/li>\n \t<li>Redirect based on the user\u2019s country<\/li>\n \t<li>A\/B testing<\/li>\n \t<li>Other functions<\/li>\n<\/ul>\nThe paid license costs $57 a year for one website. You can get a 10% discount with the coupon code 10OFF.\n<h3>Easy Affiliate Links<\/h3>\n\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;69f13e7de3ed8&quot;}\" data-wp-interactive=\"core\/image\" class=\"wp-block-image alignnone size-full wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on-async--click=\"actions.showLightbox\" data-wp-on-async--load=\"callbacks.setButtonStyles\" data-wp-on-async-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/blog.travelpayouts.com\/wp-content\/uploads\/2018\/09\/easy-affiliate-links.jpg\" alt=\"Easy Affiliate Links\" class=\"alignnone size-full\" width=\"1193\" height=\"391\"\/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\taria-label=\"Enlarge\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on-async--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.imageButtonRight\"\n\t\t\tdata-wp-style--top=\"state.imageButtonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure>\n\n\n<a href=\"https:\/\/wordpress.org\/plugins\/easy-affiliate-links\/\" target=\"_blank\" rel=\"noopener\">Easy Affiliate Links<\/a> is an alternative to Shortlinks by Pretty Links. The plugin is focused on the Amazon affiliate program but can be used for any other links. More than 10,000 people use Easy Affiliate Links for link reduction to date.\n<h3>The plugin\u2019s key points are<\/h3>\n<ul>\n \t<li>An intuitive interface<\/li>\n \t<li>Statistics<\/li>\n \t<li>Link categorization<\/li>\n \t<li>Link importing and exporting to .XML<\/li>\n<\/ul>\nThe developers also offer extra paid options, such as detailed statistics. Click location, A\/B testing, and \u201cbroken\u201d link tracking are currently under development.\n<h3>Shortlinks for Jetpack Sharing Buttons<\/h3>\n\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;69f13e7de4069&quot;}\" data-wp-interactive=\"core\/image\" class=\"wp-block-image alignnone size-full wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on-async--click=\"actions.showLightbox\" data-wp-on-async--load=\"callbacks.setButtonStyles\" data-wp-on-async-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/blog.travelpayouts.com\/wp-content\/uploads\/2018\/09\/jetpack.jpg\" alt=\"Shortlinks for Jetpack Sharing Buttons\" class=\"alignnone size-full\" width=\"1257\" height=\"632\"\/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\taria-label=\"Enlarge\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on-async--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.imageButtonRight\"\n\t\t\tdata-wp-style--top=\"state.imageButtonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure>\n\n\n<a href=\"https:\/\/wordpress.org\/plugins\/jetpack-shortlinks-for-sharing-buttons\/\" target=\"_blank\" rel=\"noopener noreferrer\">Shortlinks for Jetpack Sharing Buttons<\/a> is a plugin for redirecting on WordPress with a full set of functions for link reduction. It is mostly used as an addition to the <a href=\"https:\/\/wordpress.org\/plugins\/jetpack\/\" target=\"_blank\" rel=\"noopener noreferrer\">Jetpack<\/a> plugin to increase its options. You can track the statistics via a free plugin, Google Analytics by Yoast.\n\nThe developers note that Shortlinks for Jetpack is currently under development, so errors are possible. However, they are usually corrected very quickly. Because this project has open-source software, the issues are sent to GitHub.\n<h2>Link redirection via PHP-script and JavaScript<\/h2>\nAs we have indicated, PHP redirects work faster than JS, making them more popular among webmasters. To realize a simple redirection, add the following code to the index.php file:\n\n<!-- HTML generated using hilite.me -->\n<div style=\"background: #f8f8f8; overflow: auto; width: auto; border: solid gray; border-width: .1em .1em .1em .8em; padding: .2em .6em;\">\n<pre style=\"margin: 0; line-height: 125%;\">$links = parse_ini_file('shortlinks.ini'); \nif(isset($_GET['l']) &amp;&amp; array_key_exists($_GET['l'], $links)){\n     header('Location: ' . $links[$_GET['l']]);\n} else{\n     header('HTTP\/1.0 404 Not Found');\n     echo 'Unknown link.'; \n}\n<\/pre>\n<\/div>\nThere is no control panel in this case. All the main links are put in the shortlinks.ini file manually. Note that you should create this file manually too. Then you can write this code inside the file:\n\n<!-- HTML generated using hilite.me -->\n<div style=\"background: #f8f8f8; overflow: auto; width: auto; border: solid gray; border-width: .1em .1em .1em .8em; padding: .2em .6em;\">\n<pre style=\"margin: 0; line-height: 125%;\">Aviasales = https:\/\/www.Aviasales.com\/?marker=XXXXXX.short\n<\/pre>\n<\/div>\nAs a result, you\u2019ll get the links in yourdomain.com\/index.php?l=Aviasales format.\n\nThis sample demonstrates the common redirection of a link in WordPress via a PHP script.\n\nRedirection via JavaScript is done by a code that is placed between the tags &lt;head&gt; and &lt;\/head&gt; on the appropriate page. To do so, you should use plugins, such as <a href=\"https:\/\/wordpress.org\/plugins\/per-page-add-to\/\" target=\"_blank\" rel=\"noopener\">Per page add to head<\/a>.\n\nHere is a sample of the simple code for JavaScript redirection:\n\n<!-- HTML generated using hilite.me -->\n<div style=\"background: #f8f8f8; overflow: auto; width: auto; border: solid gray; border-width: .1em .1em .1em .8em; padding: .2em .6em;\">\n<pre style=\"margin: 0; line-height: 125%;\">&lt;script&gt;\n  window.location.href = \"https:\/\/www.Aviasales.com\/?marker=XXXXXX.short\";\n&lt;\/script&gt;\n<\/pre>\n<\/div>\nNote that it is impossible to build in the independent JavaScript code between the tags &lt;head&gt; and &lt;\/head&gt; if there is a unified design without any third-party plugins. That\u2019s why you have to create the separate template for every page or to use an <a href=\"https:\/\/wordpress.org\/plugins\/per-page-add-to\/\" target=\"_blank\" rel=\"noopener\">additional plugin<\/a> to implement the code.\n<h2>The best solution for the WordPress sites<\/h2>\nIt is only half of the story to create the link with a redirect. Then you\u2019ll have to manage the link \u2013 track statistics and change target URLs. The turnkey solutions look better than common PHP\/JS scripts as they allow you to do more with less effort.\n\nExcept the link managing that you\u2019ve already had, you can have one more problem \u2013 implementing new links on the site or replacing the old ones.\n\nFor example, you have been doing the travel blog for 4 years already but have just found out the special plugins for links. Then you have to solve the problem \u2013 replacing hundreds or even thousands of old links.\n\n<a href=\"https:\/\/wordpress.org\/plugins\/pretty-link\/\" target=\"_blank\" rel=\"noopener noreferrer\">Plugin Pretty Link in the enhanced version<\/a> is a versatile solution. In addition to redirection, it has extra auto-options:\n<ul>\n \t<li>Replace the old links for the links in a new format.<\/li>\n \t<li>Set the links for the words that haven\u2019t had them before.<\/li>\n<\/ul>\nThis plugin is great but not free. You can solve this problem just fine using two plugins \u2013 PrettyLink (free version) and a free plugin for the old links\u2019 replacement on the site.\n<h2>How to make the total replacement of the old links on the website?<\/h2>\nImportant! You should always create a backup copy of your site\u2019s database before starting the replacement!\n\nThe Plugin <a href=\"https:\/\/wordpress.org\/plugins\/better-search-replace\/\" target=\"_blank\" rel=\"noopener noreferrer\">BetterSearchReplace<\/a> will be helpful for the auto-replacement of the old links for the new ones, as well as with the positioning of references to the words. More than 50,000 active installations are currently being used. Its main options are as follows:\n<ul>\n \t<li>A massive replacement of the old links.<\/li>\n \t<li>Selecting the separate tables to work.<\/li>\n \t<li>An \u201cidle\u201d start to look through the areas that are going to be updated.<\/li>\n<\/ul>\nThis plugin will help you to update the old links or to position the new ones to the words. For example, you can put in the search the words \u201cair tickets\u201d and point the following in the area for replacement:\n\n<!-- HTML generated using hilite.me -->\n<div style=\"background: #ffffff; overflow: auto; width: auto; border: solid gray; border-width: .1em .1em .1em .8em; padding: .2em .6em;\">\n<pre style=\"margin: 0; line-height: 125%;\"><span style=\"color: #1e90ff; font-weight: bold;\">&lt;a<\/span> <span style=\"color: #1e90ff;\">href=<\/span><span style=\"color: #aa5500;\">\"https:\/\/www.Aviasales.com\/?marker=XXXXXX.short\"<\/span><span style=\"color: #1e90ff; font-weight: bold;\">&gt;<\/span>flight ticket<span style=\"color: #1e90ff; font-weight: bold;\">&lt;\/a&gt;<\/span>\n<\/pre>\n<\/div>\nThis method has some alternatives. You can use either identical plugins or make changes in MySQL database via host control panel. One more opportunity is to use the PHP-script \u201cReplace DB version 3.1.0\u201d that is available <a href=\"https:\/\/interconnectit.com\/products\/search-and-replace-for-wordpress-databases\/\" target=\"_blank\" rel=\"noopener noreferrer\">here<\/a>. It is compatible with both WordPress sites and the other popular CMS.\n\nWhile preparing this material we have tested some widespread solutions, including plugin <a href=\"https:\/\/wordpress.org\/plugins\/mts-url-shortener\/\" target=\"_blank\" rel=\"noopener noreferrer\">URL ShortenerbyMyThemeShop<\/a>. The promising description claims that you\u2019ll get tools for redirecting, managing, and implementing massive replacements for free. It could be a great alternative to the paid PrettyLinkPro, yet it does not work in practice.\n<h2>Should you redirect the affiliate links?<\/h2>\nYou should redirect links to manage your own project in the best way. The more usable the tool you select, the more efficient your work will be. The link managing systems provide more options than the manual inclusion. For example, <a href=\"https:\/\/travelpayouts.com\/blog\/a-b-and-split-tests\/\">you can make A\/B testing<\/a> of the new niche in some clicks via the target URLs replacement.\n\nCertainly, you can do manually all the plugins and scripts\u2019 settings. The question is one of the greater convenience in your work and your opportunities.\n\nWhile using the redirect, you should note that if the user cannot understand the essence of the redirection, he\/she could be annoyed. That\u2019s why you should make fine and clear shortenings, appeasing the user with every little detail about their destination when they are ready to click.\n\nShare your questions and experiences in redirection and managing the affiliate links on the site in the comments section.","protected":false},"excerpt":{"rendered":"<p>Affiliate links are one of the most effective tools for selling flight tickets, hotels, tours, and other services and goods on a travel-blog. There are several solutions for conveniently managing a great number of the affiliate links on a travel website. On this page, we have considered how to set up affiliate link redirects on the most popular CMS for the travel websites \u2014 WordPress. Here you also will find details about convenient massive link replacement.<\/p>\n","protected":false},"author":3,"featured_media":2478,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"_eb_attr":"","footnotes":""},"categories":[7],"tags":[19,77,47,55],"class_list":["post-2476","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-advices","tag-howto","tag-links","tag-website","tag-wordpress"],"acf":[],"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/posts\/2476","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/comments?post=2476"}],"version-history":[{"count":18,"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/posts\/2476\/revisions"}],"predecessor-version":[{"id":15937,"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/posts\/2476\/revisions\/15937"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/media\/2478"}],"wp:attachment":[{"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/media?parent=2476"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/categories?post=2476"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/tags?post=2476"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}