Skip to main content
Back to Tools
RFC 3986 & GA4 Standard100% In-Browser · Zero Outbound Pings

UTM Campaign URL Builder & Validator

Build, format, and validate Google Analytics UTM campaign URLs with query preservation, fragment safety, duplicate key resolution, and batch processing.

Campaign Presets
Zero outbound pings: Generated links are never fetched or tracked.

Target Destination URL

Existing query parameters (e.g. ?cat=1) and fragments (#signup) are safely preserved.

Campaign Parameters

Quick:
Quick:

Generated Campaign URL

https://draftsbook.com/blog/typescript-mastery?utm_source=newsletter&utm_medium=email&utm_campaign=weekly_digest_issue_42&utm_content=main_article_button

Parameter Breakdown

utm_sourcenewsletter
utm_mediumemail
utm_campaignweekly_digest_issue_42
utm_term(None)
Tool Documentation & Guide

UTM Campaign URL Builder & Validator Guide

Tag marketing links with standard and GA4 parameters while preserving existing queries and URL fragments.

Overview

The UTM Campaign URL Builder appends tracking parameters (utm_source, utm_medium, utm_campaign, utm_term, utm_content) to destination URLs. Unlike simple string concatenators, it parses existing query strings, places campaign parameters before URL fragments (#hash), resolves duplicate keys with configurable strategies, handles Unicode characters safely, and processes batch lists of URLs with single-click export.

How to Build UTM Campaign URLs

1Input Target URL or Batch List

Enter a single destination URL or switch to Batch mode to tag an entire list of URLs at once.

2Define Campaign Parameters

Enter campaign source (e.g. google, newsletter), medium (e.g. cpc, email), and campaign name (e.g. spring_sale). Optionally add term, content, and modern GA4 fields.

3Select Duplicate Resolution Rule

Choose how to handle URLs that already have UTM parameters: overwrite existing values, keep existing values, or append duplicate keys.

4Configure Formatting & Space Encoding

Toggle auto-lowercase values to keep analytics reports unified, and pick your preferred space format (+, %20, hyphen, or underscore).

5Copy or Download Campaign URLs

Copy the generated URL directly or download batch links as a text file for immediate distribution.

Fragment Safety & Query Preservation
Input
https://example.com/checkout?discount=SUMMER#payment-options
Output
https://example.com/checkout?discount=SUMMER&utm_source=newsletter&utm_medium=email&utm_campaign=summer_sale#payment-options

The existing query (?discount=SUMMER) is preserved, and the UTM parameters are correctly positioned before the fragment (#payment-options), preventing broken browser routing.

Standards & Formatting Guidelines
  • Fragment Integrity: Strictly enforces that query strings precede #fragments per RFC 3986.
  • Unicode Support: Non-ASCII characters (e.g. Bangla or accented letters) are safely percent-encoded in URI format.
  • GA4 Ready: Includes support for modern Google Analytics 4 dimensions (platform, creative format, tactic).
100% In-Browser Privacy
  • Zero Outbound Activity: The builder never makes network requests to test or ping generated links.
  • Confidential Campaign Names: Secret product launches and promo codes remain 100% local in your browser memory.