Skip to main content

GA4: How to create UTMs

Last Update 14/12/2022

Add parameters to URLs to identify the campaigns that refer traffic.
By campaign, we mean any marketing campaign that uses links.

When a user clicks a referral link, the URL parameters are sent to GA4 and the parameter values are visible in the Traffic acquisition report.

utm_source: Referrer, for example: google, newsletter, billboard
utm_medium: Marketing medium, for example: cpc, banner, email
utm_campaign: Product, slogan, promo code, for example: spring_sale
utm_term: Identify paid search keywords.
If you're manually tagging paid keyword campaigns, you should also use utm_term to specify the keyword.
utm_content: Used to differentiate similar content, or links within the same ad.
For example, if you have two call-to-action links within the same campaign, an email campaign for instance, you can use utm_content and set different values for each so you can tell which version is more effective.

Important note: utm_source, utm_medium, and utm_campaign are necessary

For example, you might use the following parameter-value pairs for Eskimi's India & EA Rich Media + In-Game June 2022 Newsletter campaign:

utm_source = newsletter
utm_medium = hubspot
utm_campaign = India+&+EA+Rich+Media+In-Game+June+2022

The custom campaign URL would be:
https://www.eskimi.com/?utm_source=newsletter&utm_medium=hubspot&utm_campaign=India+%26+EA+Rich+Media+%2B+In-Game+June+2022

 

URL builders
The following builders can be used in order to create the URL properly

Links to websites: Use the Campaign URL Builder.
Android-app ads: Use the Play Campaign URL Builder.
iOS-app ads: Use the iOS Campaign URL Builder.

Important: If you are advertising an Android app, use the Google Play URL Builder.
If you are advertising an iOS app, use the iOS Campaign Tracking URL Builder.
Otherwise, you should use the Google Analytics Campaign URL Builder.


Manual set up
If you want to set up your custom campaigns manually, make sure you separate the parameters from the URL with a question mark.
List the parameters and values as pairs separated by an equal sign.
Separate each parameter-value pair with an ampersand. 

https://www.example.com/?utm_source=email_campaign&utm_medium=email&utm_campaign=summer-sale

You can add parameters to a URL in any order.
Note that Analytics is case sensitive, so utm_source=google is different from utm_source=Google.
Case sensitivity applies for each value you define.


Best Practises in creating custom URLs for tracking campaings

1. If the Analytics account is linked to an active Google Ads account and you have auto-tagging enabled, you don't need to tag your destination URLs in Google Ads.
Analytics automatically tracks all of your Google Ads campaigns.

2. If you run paid search campaigns on search engines other than Google, you'll need to tag the destination URLs for those ads.

3. Referral sites are automatically detected and displayed in your reports. However, if you want to associate a campaign name or ad type (such as "banner_ad") with referral traffic, you should tag links on referral sites.

4. There are certain links that you don't need to tag, and many times are not able to tag.
You should not attempt to tag organic (unpaid) keyword links from search engines.
Search engine names are automatically detected and displayed in your reports. 

6. Use only the campaign variables you need.
The URL Builder has six fields, but you generally need to use only Campaign Source, Campaign Medium, and Campaign Name.