Text messages have limited space, so when you create a SMS campaign, you need to make every character count. With Iterable's SMS link shortening, you can squeeze in those important links without sacrificing content.
SMS shortlinks offer important benefits:
Brand recognition - If you use a custom tracking domain for link shortening, your users see links that are associated with your organization, which can increase trust and engagement.
Click tracking - Iterable tracks clicks on SMS shortlinks, so you can see how your users are engaging with your SMS campaigns.
Personalization - SMS shortlinks can redirect personalized URLs, URLs that contain UTM parameters, and URLs with Handlebars expressions, so you can track user engagement and personalize content without worrying about creating URLs that are too long.
Space-saving - Shortened links use fewer characters in your SMS messages than long, complicated URLs with personalized parameters, leaving more room for your content.
Deep linking - If you set up your tracking domain to support deep links, you can include deep links in your SMS campaigns, which can open your app on a user's device.
In this article, you'll learn how SMS link shortening works, how to set up a custom tracking domain for SMS shortlinks, and how to add UTM parameters & deep links to your SMS campaigns.
# In this article
# How SMS link shortening works
When you enable link shortening for an SMS template, Iterable replaces all of the links in the SMS message with unique shortlinks that track clicks and redirect users to the original destination URL.
For example, if you include a link to https://www.example.com/shoppingcart.htm?code=BLACKFRIDAY
in your SMS message, Iterable shortens it to a link like https://itbl.co/-KT~2NMwZ
(or https://eu.itbl.co/-KT~2NMwZ
if your organization is hosted in
Iterable's EDC)
Iterable stores shortlinks for a minimum of 30 days. If one of your users happens to click on an expired link, they will see a friendly 404 page. Occasionally, Iterable may reuse shortlink keys, but only for the same project. To reduce the chances of a link being reused, you can increase the minimum key length for shortlinks in your project settings.
# Ways to customize SMS shortlinks
There are several ways to customize SMS shortlinks:
Custom tracking domain: Use a custom tracking domain for SMS shortlinks that is associated with your organization. This can increase trust and engagement with your users.
Unique key length: Customize the length of the unique key for shortlinks in your SMS campaigns. The longer the key, the more unique shortlinks you can generate, and the more secure your shortlinks are. The shorter the key, the more space you save in your SMS messages.
Personalization: SMS shortlinks can redirect personalized URLs, URLs that contain UTM parameters, and URLs with Handlebars expressions. This allows you to track user engagement and personalize content without worrying about creating URLs that are too long.
UTM parameters: Automatically attach specific UTM parameters (and/or other URL parameters) to each link in your SMS campaign. This can help you track user engagement and campaign performance.
Deep links: Include deep links in your SMS campaigns. When a user clicks a deep link, it opens in your mobile app (if it's installed on the user's device) or in a web browser. A custom tracking domain is required to send shortened deep links in SMS campaigns.
IMPORTANT
PII security considerations
When using link shortening with sensitive information or PII, always require a login. When a shortlink expires, its random characters can be reused for a new link (only by the same Iterable project). Authentication prevents a previous recipient from accessing sensitive content found at a reused link's new destination, should a user happen to click an old link that has since been reused.
# Parts of an SMS shortlink
Each shortlink includes the following characters:
- The tracking domain (
https://itbl.co/
for USDC-hosted organizations,https://eu.itbl.co/
for EDC-hosted organizations, or a custom tracking domain) - A project connector followed by a tilde (example:
-KT~
) (only foritbl.co
) - A unique key (example:
2NMwZ
) that ranges in length by up to 6 additional characters from the minimum key length, which you can customize in your project settings.
Here is an example of an SMS shortlink that uses the default configuration:
https://itbl.co/-KT~2NMwZ
# Character length of SMS shortlinks for custom tracking domains
When you use the default settings and tracking domain, SMS shortlinks vary between 26 and 35 characters in length. Here is the breakdown:
-
https://itbl.co/
(16 characters) orhttps://eu.itbl.co/
(19 characters) - Project connector (up to 5 characters) (example:
-KT~
). Note that the tilde character (~
) is included in all project connectors, and counts as two characters. - A unique key with the minimum character count set in your project settings
(default: 5 characters), up to 6 additional characters (example: as short as
2NMwZ
and up to as long as2NMwZAAAAAA
).
When you use a custom tracking domain, the length of SMS shortlinks vary depending on your configuration:
-
http://
orhttps://
, depending on your domain's configuration (7 or 8 characters) - Your custom tracking domain with a trailing slash (example:
exmpl.co/
, 9 characters). - A unique key with the minimum character count set in your project settings,
up to 6 additional characters (example: as short as
2NMwZ
and up to as long as2NMwZAAAAAA
).
For a custom tracking domain of https://exmpl.co/
, an example SMS shortlink
with a minimum key length of five characters would be:
https://exmpl.co/2NMwZ
In this example, the total length of the shortlink can vary from 22 to 28 characters.
# Default link tracking domain: itbl.co
By default, new projects use Iterable's shortlink domain. This domain is shared across all Iterable projects and varies by data center location.
- For USDC-hosted projects:
https://itbl.co
- For EDC-hosted projects:
https://eu.itbl.co
Because itbl.co
is shared across all Iterable projects, shortlinks that use
this domain include a project connector key, which is unique to each project
and up to five extra characters. Each project connector key is up to five
characters long and is followed by a tilde (~
). The tilde character counts as
two characters.
For example, in https://itbl.co/-KT~2NMwz
, the -KT~
prefix associates the
link with the template's Iterable project. However, the campaign preview
doesn't show the actual, project-specific extra characters that appear in your
messages (only an example).
itbl.co
cannot be used to send deep links.
For link shortening, using Iterable's default domain is not a best practice for
production use. It's best to use a branded link tracking domain, instead of
itbl.co
, when sending shortlinks to your audience. Users perceive links
associated with your organization to be more trustworthy and they are more
likely to click on them.
# Using a custom tracking domain for SMS shortlinks
If you want brand recognition for your SMS shortlinks, Iterable can use your custom domain for shortlinks. This way, your users see links that are associated with your organization, which can increase trust and engagement.
You can add multiple tracking domains to a project, but you can only use one tracking domain per SMS campaign.
# Adding a custom tracking domain for SMS shortlinks
To set up a link tracking domain for SMS link shortening:
Register a domain of your choice. The shorter, the better.
-
Enable HTTPS for all tracking domains. This is not an Iterable requirement, but it's highly recommended and widely considered a best practice.
To enable HTTPS for a tracking domain, you can use a service such as Amazon CloudFront or Cloudflare.
-
In the domain's DNS, set up a CNAME record that points to the Iterable tracking domain for your host datacenter — one of the following:
-
links.iterable.com
(for a USDC-based project) -
links.eu.iterable.com
(for an EDC-based project)
NOTE
Be sure to use the correct domain for your project. Keep in mind that an organization's data center location refers to where your org's data is stored and may not correspond to your company's physical location. For more information, see Iterable's European Data Center (EDC).
-
In Iterable, log in as a user with the Manage Project Settings permission and open the project you're setting up.
Go to Settings > Domains and add this new domain as a link tracking domain, making sure to enable HTTPS. For more information, read Email Setup.
Iterable automatically verifies DNS records. Check the status in the Verified column of the Domains page. DNS changes may take time to propagate (up to 48 hours).
-
Once Iterable has verified the domain, you can use it for SMS link shortening by enabling the Shorten and Track setting in your SMS template and selecting the domain from the dropdown.
To learn more about creating an SMS template, read Creating SMS Templates.
IMPORTANT
Before using a new tracking domain in a live campaign, send an internal test campaign to make sure that it works as expected.
# Configuring a custom tracking domain to support deep links
To have your tracking domain support deep links:
- On the Settings > Domains page, add some destination domains to your tracking domain.
- For each destination domain, create an
apple-app-site-association
file. These files specify the specific paths for which your app can handle deep links. - Create an
assetlinks.json
file, so that Android devices know that your app can be trusted to open links for your destination domains.
TIP
To learn more about these steps, read Sending Domains, Tracking Domains, and Deep Links.
# Setting the minimum unique key length for SMS shortlinks
Each shortlink includes a unique key that has a minimum length (and ranges in length by up to 6 additional characters). This key is used to redirect users to the original destination URL when they click the shortlink.
You can customize the length of the unique key for shortlinks in your SMS campaigns by changing the project setting, Short Link Character Limit in SMS.
By default, keys are a minimum of five characters long and up to 11 characters long. You can change the minimum key length in your project's settings for transactional and marketing message channels to use different key lengths.
The longer the key, the more unique shortlinks you can generate, and the more secure your shortlinks are. However, longer keys take up more space in your SMS messages.
To learn how to change the minimum key length for shortlinks in your project, read Project Settings Overview: Short Link Character Limit in SMS.
# Shortlink key generation
For each link in your message, the actual number of characters used for each unique key is determined at send time and is always at least the minimum length you've set in your project settings, and at most the minimum length plus six additional characters.
Here's how it works:
- Iterable tries up to 5 times to find an available unique key of the minimum length set in your project settings.
- If it cannot find one, Iterable tries up to 5 times to find an available unique key with one additional character.
- This process continues, adding one character at a time, up to a maximum of 6 additional characters.
The longer the minimum key length, the easier it is for Iterable to find an available key. Each character in the shortlink key has 64 possible options, so as the key length increases, the likelihood of finding an available shortlink key within 5 tries also increases.
# Using shortlinks in SMS campaigns
To use link shortening in your SMS campaigns, enable link shortening in your SMS template. When you do this, Iterable uses your selected tracking domain to shorten the SMS campaign's links, regardless of where they come from (manual entry in the message's content, a Handlebars expression, or a snippet).
# Using Handlebars to insert URLs for SMS campaigns
If you're using Handlebars to insert a link into an SMS message, use triple curly bracesfavoriteItemURL
profile field that you'd like
to use as a link in your message, enter {{{favoriteItemURL}}}
, not
{{favoriteItemURL}}
.
# Adding UTM parameters (and other customer parameters) to SMS shortlinks
SMS campaigns in Iterable can automatically attach specific UTM parameters (and/ or other URL parameters) to each link in their message content.
When you enable UTM parameters for an SMS campaign, Iterable adds the following parameters:
?utm_source=Iterable&utm_medium=sms&utm_campaign=campaign_{{campaignId}}
(Where {{campaignId}}
gets replaced with the ID of your campaign.)
These parameters are added before the link is shortened. They won't appear directly in the message, but they are available after the shortlink is resolved to its intended destination (in your app, or in the browser).
To learn how to add UTM parameters and other custom URL parameters to your SMS campaigns, read Creating SMS Templates.
IMPORTANT
In SMS campaigns, Iterable only attaches UTM parameters (and other custom URL parameters) to shortened links. Standard links with UTM parameters can get quite long, which is a problem for a character-constrained medium like SMS. If you don't enable link shortening and tracking for an SMS campaign, URL parameters you configure for it won't be added to the sent message.
# Adding deep links to SMS campaigns
After creating a tracking domain, you can use it to include deep links in your SMS campaigns. When a user clicks a deep link, it opens in your mobile app (if it's installed on the user's device), or in a web browser.
You can recognize a deep link sent with Iterable by the /a
in its URL. For
example, an SMS campaign using itbldocs.site
as a link tracking domain
creates deep links that look like this: https://itbldocs.site/a/KT~2NMwZ
.
To send a deep link in an SMS campaign:
When setting up the SMS campaign, enable the Shorten and Track setting as you're setting up the campaign content (template). To learn more, read Creating SMS Templates.
Select a tracking domain that's set up for deep linking (as described above).
Add a link to your message content, making sure that it matches a destination domain and path associated with the specific tracking domain you've selected for the campaign.
To test that deep links are working as expected, send a proof of the campaign to yourself, inspect the link, and try clicking on it to make sure that it opens in your app.
# Considerations for deep links in SMS campaigns
Some things to remember when sending deep links in your SMS campaigns:
The default tracking domain,
itbl.co
, cannot be used to generate and send deep links (since you can't create anapple-app-site-association
file for this domain).If your mobile apps (iOS, Android, React Native) have been set up to handle deep links from emails and push notifications, you don't need to write any extra code to support deep links from SMS messages.
The character count on the Preview with Data page does not account for the two characters added by the
/a
in the deep link's URL.If the links you add to your SMS message don't match the destination domains you've defined for the tracking domain you've selected for the campaign (or the paths defined in their associated
apple-app-site-association
files), Iterable does not rewrite those links as deep links.To make sure that deep links are working as expected, always send yourself a proof of an SMS campaign before activating or sending the campaign.
Deep links can include UTM and other custom parameters. These URL parameters are added to your links before they're shortened and converted to deep links.
# Tracking SMS clicks
Whenever a user clicks a shortlink in an SMS message, Iterable saves an
smsClick
event to their profile. You can use these events to:
- Segment a list
- Trigger a journey
- Filter users in a journey
- Trigger a system webhook
For example, you might create a dynamic list that includes only those users who have (or have not) clicked on a particular SMS message. Or, you might use them to split users into different journey paths.
Additionally, Iterable surfaces various SMS click tracking metrics:
- Total SMS clicks
- Unique SMS clicks (
smsClick
by unique user) - SMS click rate (unique SMS clicks / total SMS delivered)
You can find these metrics in all the places you analyze campaign metrics: messaging insights, reports, dashboards, experiments, etc.
# SMS click event properties
Each SMS click event tracked contains properties that provide information about the click event, the user who clicked, and the campaign that contained the link. Some properties are automatically included in the event, while other properties vary and are included when applicable, depending on many factors.
# clickedUrl
property
The clickedUrl
property contains the original URL used in the campaign
template (not the shortened version). This is helpful for tracking which links
users clicked on in your SMS messages and for troubleshooting issues such as
UTM parameters not being passed correctly and broken links.
You can also use this field for personalization, segmentation, and journey filters.
# Example smsClick
event
Here's an example JSON body of an smsClick
event:
{ "campaign": { "campaignAlertsEnabled": false, "campaignState": "Running", "createdAt": 1712597831903, "createdByUserId": "marketing@example.com", "dataScienceOptimizations": [], "id": 1234567, "ignoreFrequencyCap": false, "isArchived": false, "isDryRun": false, "isHidden": false, "labelIds": [], "messageMedium": "SMS", "mobileAppIds": [], "name": "My SMS Campaign Name", "projectId": 00000, "teamId": 00000, "templateId": 12345678, "updatedAt": 1731088978882, "updatedByUserId": "marketing@example.com", "useCustomRateLimit": false, "wasEverRecurring": false }, "campaignId": 1234567, "clickedUrl": "https://www.example.com/", "createdAt": "2024-11-08T18:05:56.000Z", "email": "user@example.com", "userId": "some-user-id", "eventType": "smsClick", "itblInternal": { "documentCreatedAt": "2024-11-08 18:14:42 +00:00", "documentUpdatedAt": "2024-11-08 18:14:42 +00:00" }, "messageId": "e98354206abb484da8a9a5abcd6523ef", "templateId": 12345678, "userAgent": "Mozilla/5.0 (Linux; Android 10; K) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.0.0 Mobile Safari/537.36", "userAgentDevice": "Other" }
# Want to learn more?
For more information about some of the topics in this article, check out these resources. Iterable Academy is open to everyone — you don't need to be an Iterable customer!
Iterable Academy
Support docs