Re: Automatically append UTM codes to links within an email

Meg_Stout
Level 2

Automatically append UTM codes to links within an email

Hello! I've searched the community but haven't found a clear answer to this yet. We deploy a large number of newsletters, all of which share the same UTM codes. We have implemented local variables (in Editor 2.0) to help with tagging. But users are still forgetting to add "${utm-tag}" at the end of every link they insert.

Is there a way, either with tokens or global variables, to define UTM codes at the template level so they are automatically appended to every link?

8 REPLIES 8
Yanir_Calisar2
Level 3

Re: Automatically append UTM codes to links within an email

Hi,

I've developed a free Chrome extension - UTM Builder for Marketo (http://bit.ly/UTM-Builder-For-Marketo​).

It's not a really automatic solution but it's annoying enough and might make more people remember to add these UTM's .

Kyle_McCormick
Level 5

Re: Automatically append UTM codes to links within an email

Hi Meg,

I'd recommend using tokens, especially if you have multiple links or buttons in the email.  We have our tokens on the folder level, but you can easily have them in your templates as well (just depends on how much these will be changing). All of our tokens are on the folder level because we want every email sent that sits in that particular folder to have consistent UTMs.  What this looks like for us in the email link is two tokens: {{my.Em-6 Digital Asset URL}}{{my.Email Tracking utm}}

{{my.Em-6 Digital Asset URL}} should be a local token in the template where your email manager updates the link to the asset

{{my.Email Tracking utm}} should be either an inherited or local token for the utms.

This way the field will not need to edit the link in the email and only edit it in the token, guaranteeing the UTM token stays in place.

Meg_Stout
Level 2

Re: Automatically append UTM codes to links within an email

Thanks Kyle! To make sure I understand, this would still require the user to insert "{{my.Em-6 Digital Asset URL}}{{my.Email Tracking utm}}" everywhere there is a link in the email editor?

Kyle_McCormick
Level 5

Re: Automatically append UTM codes to links within an email

Yes it does, however you could also append your templates so every button has both tokens. If there is ever at a time you don't want utm tracking in the links, just replace the token values with a space.

David_Gallaghe2
Level 5

Re: Automatically append UTM codes to links within an email

It sounds like you are using email variables when you should be using tokens as noted above.

I figured out the hard way that variables will not render when they are in an editable are of an email... ie image alt tag, a href etc. The intent is that you can drop in a module, update the text box on the right side and your variables are set. done. Reality hits as you noticed when those variables render as themselves rather than the intended content.

  1. I like using tokens for links in emails. Make sure that the http:// or https:// is hard coded before your token.
    1. https://{{my.EM - CTA Primary URL}}
    2. https://{{my.EM - CTA Secondary URL}}
    3. https://{{my.EM - CTA Tertiary URL}}
    4. Why? If you include the http:// or https:// in the token, marketo will not generate a tracking redirect link when it renders.

  2. Setup your UTMs as tokens and hardcode what makes sense...ie:
    1. https://{{my.EM - CTA Primary URL}}?{{my.EM - utm_campaign}}&utm_medium=email&utm_source=company&utm_content=newsletter&{{my.utm_term}}-button

I usually have tokens ready and raring to go for each of my utms, but in certain cases, like this one, it makes sense to simply hard code what makes sense. I also mix-up the utm_term by combining a token with a dash and a fixed value based on the link location... -logo, -cta, -text -link, -ps, -footerlink and so forth...

This has helped me quite a bit, but up to you how you want to role .

Sidenote: Source does not always = Source

With that said be cautious how you use and map your UTM SOURCE and UTM Medium. It is common that companies will link utm source directly to lead source during form fills, note that Lead/Person Source typically refers to the the general medium of entry ie: email, landing page, purchased list. This is much more like the UTM Medium by google standards. UTM Source is usually the name of the actual source, ie: google, facebook, etc.

I know this was a bit long winded, but I hope this brings more clarity than confusion

Mark_Price
Level 7

Re: Automatically append UTM codes to links within an email

Hi Meg,

Most often, I use program tokens for utm_source, utm_medium, utm_campaign.  This makes it so that after making 3 small edits all links in the email update. For more advanced implementations you might use the module variables for extra data points such as utm_term or utm_content. 

You can set the link destination either in a token or in the module.  The determining factor for me is how complicated the message is + how many CTAs there are.

Here's schematic that might help.

sws-utm-recipe.png

Milena_Mitova
Level 2

Re: Automatically append UTM codes to links within an email

You can try http://www.campaigntrackly.com. The Chrome extension lets you grab any link with a right-click action and open a pop up that will let you add pre-configured tagging templates. You can also track your campaigns and reports and it builds short links for you on the fly. It has multi-user access and numerous integrations and productivity features. Good Luck.

SanfordWhiteman
Level 10 - Community Moderator

Re: Automatically append UTM codes to links within an email

This post isn't allowed by Community rules, Milena:

pastedImage_0.png