Smart routing
Send visitors to different places by country, device or language, split traffic, open your app, and stop after a number of clicks.
Business plan. Smart routing sends different visitors to different places from one short link: by country, device or language, by sharing traffic between versions of a page to see which works better, or by opening your app on a phone. Any link can also stop working after a set number of clicks (Pro and above).
How it works
When someone follows the link, we decide where to send them in this order:
- Rules, from the top. The first rule that matches the visitor decides.
- Split traffic, for everyone no rule matched, if you've set one up.
- Otherwise, the link's own destination.
On an iPhone, iPad or Android phone, if the link has an app link for that phone, the visitor gets a short page that opens the app, and goes on to the website if the app doesn't open. The decision is made instantly, without slowing the redirect. Campaign UTM tags, conversion tracking and the visitor's own address parameters work the same for every destination.
Set it up on the link's page in Links, under Smart routing, or under Smart routing when creating a link.
Rules by country, device and language
A rule has up to three conditions and a destination. Fill in only the ones you need. A visitor matches when they match every condition you filled in:
- Countries: two-letter codes separated by commas, such as
AU, NZ. The visitor matches if they're in any of them. - Devices: iPhone and iPad, Android, Windows, Mac or other devices. Any ticked device matches.
- Languages: the language the visitor's browser prefers, such as
en,frorzh. Use the language only, not the region (en, noten-AU).
For example, a rule with countries AU and device iPhone and iPad catches Australians on an iPhone; Australians on Android and New Zealanders on an iPhone carry on to the next rule. Put the most specific rules first. A link can have up to 20 rules.
Country needs set-up on your own server
On our hosted service countries work straight away. If you run the service yourself, countries come from your proxy (such as Cloudflare); until that's set up, rules by country never match and visitors fall through to the next rule.
Split traffic between destinations
Split traffic shares visitors between two to five destinations, so you can compare them, for example two versions of a landing page. Give each a weight: 50 and 50 is an even split, 80 and 20 sends four in five visitors to the first.
- The same person keeps getting the same destination while they use the same browser and connection, so they don't see a different page each time.
- Rules still come first: the split shares only the visitors no rule matched.
- Changing the weights moves some people to a different destination. Keep the weights steady while you're comparing.
Turn on conversion tracking for the link to compare sign-ups or sales for each destination, not just clicks.
Open your app
Add an app link for iPhone and iPad, Android, or both. Use the address your app registers, such as myapp://product/42, an Android intent: link, or an https link that your app handles. On a matching phone, the visitor sees a short page that tries the app and goes to the website after a moment if the app doesn't open. They can also choose either button themselves.
- Link previews (in messaging apps and social networks), email scanners and bots always get the website.
- If your app supports universal links (iPhone) or app links (Android) for your website's addresses, you may not need this: the phone opens the app from the website's address by itself.
Stop after a number of clicks
Under More options (or in the edit form), Stop after this many clicks makes the link expire once that many clicks from people have been counted. Bots and link previews don't count. Visitors then see a page saying the link has expired.
- Clicks are counted within a few seconds, so on a busy link a few more people may get through before it stops. It's a target, not an exact cap.
- Raise the limit, or clear it, to bring the link back.
- The link list shows it under Expired.
See how each one does
The link's page shows a Smart routing table: clicks from people for each rule and split destination, their share, and with conversion tracking, conversions, conversion rate and value. Download it by day with CSV. Rules and destinations keep their figures when you edit them; one you remove shows as Removed rule while it still has clicks in the period.
Privacy
Routing uses only what every browser sends with a visit: the country (from the visitor's network), the device and the preferred language. To keep a visitor on the same split destination, we work out a number from their network (the first three parts of the IP address) and browser, mixed with a secret key, and nothing is stored on their device or with us. We never keep the full IP address.
With the API
Send routing and maxClicks when you create or change a link:
JSON body for POST /links
{
"destinationUrl": "https://example.com/spring-sale",
"routing": {
"rules": [
{ "name": "New Zealand", "countries": ["NZ"], "destinationUrl": "https://example.co.nz/spring-sale" },
{ "name": "French speakers", "languages": ["fr"], "destinationUrl": "https://example.com/fr/soldes" }
],
"split": [
{ "name": "Short page", "destinationUrl": "https://example.com/landing-a", "weight": 50 },
{ "name": "Long page", "destinationUrl": "https://example.com/landing-b", "weight": 50 }
],
"app": { "iosUrl": "exampleshop://sale", "androidUrl": "intent://sale#Intent;scheme=exampleshop;package=com.example.shop;end" }
},
"maxClicks": 5000
}
Each rule and split destination gets an id. Send the ids back when you change routing, so the analytics keep counting each one as the same rule or destination. The link report lists the figures for each under routes.
Common problems
- A rule never matches
- Check rules higher up don't catch the same visitors first. For countries, check your own server passes the visitor's country (see above). For languages, use the two-letter code only.
- I keep getting the same split destination
- That's by design: the same browser on the same connection gets the same destination. Try another browser, or a phone on mobile data.
- The app doesn't open
- Check the app link works on its own (paste it into Notes and tap it). Some apps only register universal links; use the https address in that case.
- The link expired sooner or later than I expected
- Only clicks from people count, and the count catches up within a few seconds. The link's page shows the clicks counted so far.
Something missing or unclear? Tell us and we'll improve this page.