URL variables are additions to the end of a standard URL in order to accomplish one of the following functions:
-
Add UTM tracking tags in order to pass information to your Google Analytics account
-
Pass a specific offer to your clients
-
Pass information for Survey platforms
In this article we'll go through the different variable types, each of the use cases above, as well as discuss any nuances that are specific to the Cortex platform.
In order to understand the different use cases, we first need to familiarize ourselves with the different variable calls available and their terminology.
General Variables
Terminology break-down:
- The questions mark (?) identifies the beginning of the query string and must be placed between the link and the contents of the query string.
- The ampersand (&) is used before each subsequent variable/value pair in the query string.
- The equals sign (=) separates the variable from the value assigned to that variable
- UTM - A UTM code is a simple code that you can attach to a custom URL in order to track a source, medium, and campaign name. This enables Google Analytics to tell you where searchers came from as well as what campaign directed them to you. If you are using GA, you probably want to use Auto-UTM Tagging.
Take the following example link:
https://sunbasket.com/
If you wanted to pass a variable with the value equal to the word 'value,' you can add the following to the email link:
?variable=value
Your link would look as follows:
https://sunbasket.com/?variable=value
If you wanted to add a variable named 'userid' with a value of '121,' and also include a variable 'name' with a value of 'James' your link would be constructed as follows:
https://sunbasket.com/?userid=121&name=James
Cortex Link Structure:
Non-Dynamic Standard Links
When utilizing a static link that directs a user to a specific location and not determined by a Cortex Merge Tag it's important to understand how Cortex tracks emails through its own variable.
In order to track individual users and the offers that they received, Cortex will automatically append a variable called "rs_oid". This is specifically for tracking RS emails and will have no effect on your other variable calls. An example of this auto-append can be seen below:
https://sunbasket.com/?rs_oid=123
If you wanted to pass a variable with the value equal to the word 'value,' you can add the following to the email link:
?variable=value
Your link would look as follows:
https://sunbasket.com/?variable=value
Once sends begin your link will be auto-appended to include the Cortex tracking variable and will add your variable as the next variable in the string separated by an ampersand (&).
The link above will result in:
https://sunbasket.com/?rs_oid=123&variable=value
Cortex Dynamic Links:
When utilizing a link from a Cortex Merge Tag it's important to follow a slightly modified structure in your variable calls. As mentioned above, this will have no effect on your variable to be passed, but should be followed in order to maintain an accurate URL structure.
In the example below, we will use the {{rs_rpu1}} merge tag as an example.
{{ rs_rpu1 }}: This merge tag references a URL from the product feed that is synched with ReSci. Any of our product URL merge tags (ends in rpu#) can be used in a location for links. Two examples are below:
HTML: <a href="{{ rs_rpu1 }}">
Template Builder:
If you want to pass a variable with the value equal to the word 'value,' you can add the following to the email link:
<a href="{{ rs_rpu1 }}&variable=value">
Notice the difference in this structure is that instead of utilizing a question mark (?) after the link you will use an ampersand (&). Your link will look like the example below when it is sent:
https://sunbasket.com/product1?rs_oid=123&variable=value
Understanding Link Structure for Passing UTM
Update (12/21/2017): Cortex now supports Auto-UTM Tagging on your links. Use these instructions to augment your auto-tagging setup, or if you prefer not to auto-UTM-tag.
Follow the guidelines shown above for determining how to structure your links, based on if the link is dynamic or static.
Once you determine if the link structure should utilize a question mark (?) or an ampersand (&) you should determine what UTM variables to pass over to your Google Analytics platform. This URL builder will help you structure your links correctly (remember that if you use a merge tag for your URL to change the ? to an &).
There are five basic UTM variables that you can pass over to Google Analytics. They are:
- Campaign Source (utm_source) - Use
utm_source
to identify a search engine, newsletter name, or other source. - Campaign Medium (utm_medium) - Use
utm_medium
to identify a medium such as email or cost-per-click. - Campaign Name (utm_name) - Used for keyword analysis. Use
utm_campaign
to identify a specific product promotion or strategic campaign. - Campaign Term (utm_term) - Used for paid search. Use
utm_term
to note the keywords for this ad. - Campaign Content (utm_content) - Used for A/B testing and content-targeted ads. Use
utm_content
to differentiate ads or links that point to the same URL.
Each of the above sources will have a value associated with it. To determine the variable you'd like to use, it's best to think about this from a reporting standpoint.
For example:
campaign_source can be ReSci or it can be New To Your Brand. The differentiation here is that in Google Analytics you would be able to separate out ReSci content or email content by stage. Depending on how you want to roll up your data analysis either will work well.
As an example we can take the link structure that Fun and Function uses to pass data to their Google Analytics dashboard.
https://funandfunction.com/weighted-compression-vest.html?utm_source=new-high-intent&utm_medium=email&utm_campaign=welcome2&utm_content=vest
The variables, comes after the equals sign (=) as explained above, are in bold above and as you can see they have passed quite a few parameters in order to identify where in Cortex this link click originated from:
- utm_source: In this case they are using the stage name as the tracking metric
- utm_medium: The variable they pass here is "email", it's important to not that Google Analytics will treat email and Email as different reporting items
- utm_campaign: The variable they pass here is the name of the template that contains this link
- utm_content: The variable here is vest - indicating that the user clicked on the link for the vest
This allows Fun and Function to group items in their Google Analytics platform for further analysis. The screenshot below shows a custom report that is set up in their GA account to track the different stages:
Understanding Link Structure for Passing a Specific Offer
If you want a specific offer to be displayed on your site when a user clicks through an email you'll need to do two things:
- Work with your technical team so that they can read a value that is passed in the URL
- Construct your links so it includes the offer that you would like to show
We'll cover item 2, so that you can structure everything properly.
Sun Basket does a great job of utilizing Cortex's Incentive Optimizer to pass the offer in their URL. You can also use a static offer variable in place of the incentive merge tag example below:
https://www.companyname.com/menu?offer={{rs_icode}}&utm_source=sbemail&utm_medium=email&utm_term=prospects&utm_content=orig_email2_menu&utm_campaign=welcome2_RS
As you can see above the first variable they pass is an offer={{rs_icode}}. When a user activated this link and is directed to site, the user is automatically directed to a menu page that generates an offer onsite.
You can utilize a static offer in place of the merge tag, but the important thing to note, is that your tech team must be able to ingest the variable and display the offer on-site.
- rs_oid appended automatically
- {{re_icode}} merge tag populated with actual incentive code
- Offer populated onsite based on an offer variable
Understanding Link Structure for Passing a User Id or Email to A Survey Platform
Sun Basket also uses variables to pass information to Survey Monkey for conducting surveys of their customers in order to improve their product. In this case they are able to automatically populate the user_id and email so that they can automatically populate fields and track within Survey Monkey.
https://www.surveymonkey.com/r/recipebook17?id={{rs_urid}}&e={{email}}
As you can see they use the variable terms of:
- id - this is the record_id that Sun Basket passes in their flat file and allows them to identify the user as they begin the survey
- e - this is the email of the user and allows the survey to begin with the email field already populated
Whichever survey provider you use, please be sure to identify what variables they can accept and use the list of merge tags to identify how to dynamically pass that data.
If you have additional questions on link structure please contact help@retentionscience.com. You can discuss any strategic initiatives and reporting in GA with your CSM.
Comments
0 comments
Please sign in to leave a comment.