Skip to main content
CalcChef

UTM Builder

Build a campaign URL with utm_source, utm_medium, utm_campaign, utm_id, utm_term and utm_content. Source, medium and campaign are required. How it works

Use the UTM Builder

Only http and https addresses. A host name such as example.com gets https:// added.

Values are trimmed and limited to 200 characters. Spaces become %20. Everything else in your URL stays exactly as typed; a utm parameter you fill in replaces the same one already in the URL.

Generated URL

https://example.com/landing?utm_source=newsletter&utm_medium=email&utm_campaign=spring_sale
  • https:// was added because the address had no scheme.

About the UTM Builder

example.com/landing with source newsletter, medium email and campaign spring_sale becomes https://example.com/landing?utm_source=newsletter&utm_medium=email&utm_campaign=spring_sale. Google Analytics says to always use utm_source, utm_medium and utm_campaign, and this UTM builder requires those three, adds utm_id, utm_term and utm_content when you fill them in, and percent-encodes each value, so a space becomes %20.

UTM parameters in the builder

ParameterFieldRequired hereWhat Google Analytics uses it for
utm_idCampaign IDNoThe ID of a campaign or promotion, matching the IDs used to upload campaign data
utm_sourceCampaign sourceYesThe referrer, such as google, newsletter4 or billboard
utm_mediumCampaign mediumYesThe marketing medium, such as cpc, banner or email
utm_campaignCampaign nameYesThe product, slogan or promo code, such as spring_sale
utm_termCampaign termNoThe paid keyword
utm_contentCampaign contentNoWhich creative was clicked, such as one of two links in an email

Google Analytics also reads utm_source_platform, utm_creative_format and utm_marketing_tactic, which this builder does not add; its help page says the last two are not currently reported.

Example campaign URLs

Website URLValuesGenerated URLNote
example.com/landingsource newsletter, medium email, campaign spring_salehttps://example.com/landing?utm_source=newsletter&utm_medium=email&utm_campaign=spring_salehttps:// was added because the address had no scheme.
https://example.com/landing?ref=home#topsource newsletter, medium email, campaign spring_salehttps://example.com/landing?ref=home&utm_source=newsletter&utm_medium=email&utm_campaign=spring_sale#top(none)
https://example.com/?utm_source=old&a=b%20csource newsletter, medium email, campaign spring_salehttps://example.com/?a=b%20c&utm_source=newsletter&utm_medium=email&utm_campaign=spring_saleReplaced the utm_source already in the address.
https://example.com/source Google Ads, medium email, campaign Spring Salehttps://example.com/?utm_source=Google%20Ads&utm_medium=email&utm_campaign=Spring%20Sale(none)
https://example.com/the same, with Lowercase all values tickedhttps://example.com/?utm_source=google%20ads&utm_medium=email&utm_campaign=spring%20sale(none)
https://example.com/id abc123, source newsletter, medium email, campaign spring_sale, term running shoes, content top linkhttps://example.com/?utm_id=abc123&utm_source=newsletter&utm_medium=email&utm_campaign=spring_sale&utm_term=running%20shoes&utm_content=top%20link(none)
mailto:[email protected]source newsletter, medium email, campaign spring_sale(no URL)Only web addresses that start with http:// or https:// are supported; "mailto:" links are not.

Frequently asked questions

Are UTM parameters case-sensitive?
Yes. Google Analytics treats utm_source=google and utm_source=Google as different values, so one campaign can split into two rows. Tick Lowercase all values: source Google Ads then becomes utm_source=google%20ads.
Should I use spaces or underscores in UTM values?
Either works. A space is written as %20, so Spring Sale becomes utm_campaign=Spring%20Sale; underscores and hyphens stay as typed, as in spring_sale, and read more cleanly in the address bar.
What happens if my URL already has parameters or a # fragment?
They are kept exactly as typed. ?ref=home stays first, the utm parameters follow it, and #top stays at the end. A utm parameter that is already in the address is replaced, and a note says which.
Which UTM parameters are required?
Google Analytics’ help says to always use utm_source, utm_medium and utm_campaign when you tag a link, and this builder will not produce a URL until those three are filled in. Google also recommends utm_id; utm_term and utm_content are optional.
Can I add UTM tags to a mailto link or an app link?
No. Only http and https addresses are accepted; mailto:, javascript:, data: and ftp: get a message. A host with a port, such as localhost:3000/x, is accepted and gets https:// in front.
How should a team name its UTM values?
Google Analytics asks for a strict naming convention and lowercase as standard practice, because SpringSale and Spring_Sale count as two campaigns. Agree one spelling per source, medium and campaign, keep the list in a shared sheet, and copy from it. Newsletter, Email and Spring Sale with Lowercase all values ticked give https://example.com/?utm_source=newsletter&utm_medium=email&utm_campaign=spring%20sale; typing spring_sale instead gives utm_campaign=spring_sale, with no %20 to read around. Tag the links that bring people in from elsewhere, such as emails, ads and posts: the values describe the campaign that referred the visit, so links between your own pages need none.

Related Tools

View all tools