How to Track Campaign URL in Google Analytics
Ever feel like you’re throwing marketing spaghetti at the wall just to see what sticks? You're running ads, sending emails, and posting on social media, but at the end of the month, it's a mystery which activities actually moved the needle. Tracking your campaign URLs in Google Analytics is the single best way to solve this riddle. This article will show you exactly how to tag your links and find the campaign data inside GA4, turning your generic traffic reports into a clear roadmap of what’s truly working.
What Are Campaign URLs (And Why Should You Care)?
A campaign URL is simply a standard web address with a few extra pieces of information tacked onto the end. These little additions, called UTM parameters, act like name tags for your traffic. Without them, Google Analytics knows someone visited your site, but it can’t tell if they came from your July newsletter, a specific Facebook ad, or an influencer's bio link.
When you add these parameters, you are explicitly telling Google Analytics:
Where the visitor came from (e.g., Facebook, Google, a partner blog).
How they got here (e.g., a paid ad, an email, an organic social post).
Why you sent them (e.g., your summer sale, a Q3 webinar promotion).
Think of it like this: if you just send out mail, you can see how many people reply. But if you put a unique tracking code on the mail sent to different neighborhoods, you can see not only how many people reply, but also exactly which neighborhoods were most responsive. That’s what campaign URLs do for your digital marketing. They replace guesswork with data.
The Building Blocks: A Quick Guide to UTM Parameters
"UTM" stands for "Urchin Tracking Module," a name left over from a company Google acquired ages ago. These parameters are the core of campaign tracking. While there are five standard parameters, you’ll primarily use the first three for most of your tracking needs.
utm_source: Where is the traffic coming from?
The utm_source parameter identifies the specific platform or source that sent the traffic. It answers the question, "Which website or app sent this user?" Being clear and consistent here is vital.
Examples:
google,facebook,newsletter,linkedin,partner_blog_name
utm_medium: How did the traffic get here?
The utm_medium classifies the general type of marketing channel. It answers the question, "What kind of link did they click?" Common mediums include cost-per-click ads, email, and organic social media posts.
Examples:
cpc(for paid ads),email,social_organic,affiliate,display
utm_campaign: Why is the traffic coming?
The utm_campaign parameter identifies your specific marketing initiative. It’s the "name" of your promotion. This allows you to group all the traffic related to one effort, even if it comes from different sources and mediums.
Examples:
summer_sale_2024,q4_webinar,july_newsletter_promo
Optional Parameters for Advanced Tracking
There are two other parameters that can add even more granularity:
utm_term: This is typically used to identify the specific paid keywords you're bidding on in a search campaign. For example:
blue_running_shoes.utm_content: This helps differentiate links that point to the same URL within a single email or ad. For example, if you have a button link and a text link in an email, you could tag them
cta_buttonandheader_linkto see which one gets more clicks.
When put together, they look like this:
https://www.yourstore.com/special-offer?utm_source=facebook&utm_medium=cpc&utm_campaign=summer_sale_2024
Looking at this URL, you know instantly that any visitor arriving through it came from a paid Cost-Per-Click ad on Facebook as part of the "Summer Sale 2024" campaign.
How to Create Campaign URLs (Without The Headache)
Manually typing out these URLs is a recipe for typos and broken links. Thankfully, there are tools that make this process completely painless.
Using Google's Campaign URL Builder
Google offers a free, easy-to-use tool called the GA4 Campaign URL Builder that does all the work for you. Here’s how to use it:
Navigate to the GA4 Campaign URL Builder.
Enter your website URL: Paste the full URL of the landing page you want to send people to (e.g., https://www.yourstore.com/products/new-arrival).
Enter your campaign parameters: Fill in the fields for
utm_source,utm_medium, andutm_campaign. As you type, the tool will automatically build the final URL at the bottom of the page.Copy the final URL: Once you've filled everything out, simply copy the generated URL. This is the link you'll use in your ad, email, or social post.
The tool conveniently handles all the formatting characters like ? and & for you, ensuring your URL is structured correctly.
Tips for Consistent and Clean UTM Tagging
Disorganized UTMs can be almost as bad as no UTMs at all. A little bit of discipline goes a long way. Follow these best practices to keep your data clean and easy to analyze.
Stay Consistent: Decide on a naming convention and stick to it. For example, always use
facebook, notFacebook,FB, orface-bookinterchangeably. Google Analytics is case-sensitive, so it will treat these as three different sources.Use a Spreadsheet: Create a simple shared spreadsheet (like a Google Sheet) for your team to log the UTMs they create. This prevents overlap and enforces the naming convention you've set.
Keep it Simple and Lowercase: Always use lowercase letters. It eliminates case-sensitivity errors.
Use Underscores or Dashes for Spaces: URLs can't contain spaces. Use underscores (
_) or dashes (-) instead. For example, usesummer_sale, notsummer sale.Most Importantly: Never Use UTMs on Internal Links: Never tag a link that goes from one page of your website to another. For example, don’t put a UTM-tagged URL on your homepage header banner that links to a product page. Doing so will overwrite the original source data for that visitor and break your attribution tracking. Campaigns are for external traffic only.
Finding Your Campaign Data in Google Analytics 4
Now for the payoff. Once you've started using your shiny new campaign URLs, the data will begin flowing into GA4. Here's how to find and analyze it.
Follow these steps:
Log in to your Google Analytics 4 property.
In the left-hand navigation menu, go to Reports > Acquisition > Traffic acquisition.
You’ll land on a report that initially groups traffic by "Session default channel grouping." This gives you a high-level view (Organic Search, Paid Search, Direct, etc.), but we want to see our specific campaigns.
Look for the primary dimension dropdown menu just above the main data table (it will say "Session default channel grouping"). Click it.
In the search bar that appears, type "campaign" and select Session campaign.
The report will now repopulate, showing you a list of all your utm_campaign names. Here, you can see key engagement and conversion metrics for each campaign, like total users, sessions, conversion events, and total revenue. You can finally see, side-by-side, which campaigns are performing best.
Adding Secondary Dimensions for Deeper Analysis
To get even more detail, you can add a secondary dimension. Let's say you want to see which sources and mediums drove traffic for your summer_sale_2024 campaign.
Click the blue + icon next to the "Session campaign" dropdown you just used.
In the search bar, type "source" and select Session source / medium.
Now your report will show you a breakdown of each campaign by its specific traffic sources. You might see something like this:
summer_sale_2024 / google / cpc: 50 sales
summer_sale_2024 / facebook / cpc: 25 sales
summer_sale_2024 / newsletter / email: 75 sales
This level of detail is a game-changer. It tells you that for this specific campaign, your newsletter was far more effective at driving sales than your paid advertising efforts.
Putting It All Together: Real-World Scenarios
Let's look at how this applies in practice.
Scenario 1: The E-commerce Store's Flash Sale
An online Shopify store is running a 48-hour flash sale. They're promoting it with Facebook Ads, an email to their customer list, and a post on Instagram.
Email Link:
.../?utm_source=klaviyo&utm_medium=email&utm_campaign=flash_sale_q3Facebook Ad Link:
.../?utm_source=facebook&utm_medium=cpc&utm_campaign=flash_sale_q3Instagram Bio Link:
.../?utm_source=instagram&utm_medium=social_organic&utm_campaign=flash_sale_q3
By checking their GA4 "Session campaign" report and adding "Session source / medium" as a secondary dimension, the store owner can see not only how many shoppers came from the flash sale campaign but also which channel—email, Facebook, or Instagram—generated the most revenue.
Scenario 2: The SaaS Company's Webinar Promotion
A B2B software company wants to drive signups for an upcoming webinar. They are promoting it on LinkedIn, through a partner's newsletter, and with Google search ads.
LinkedIn Post Link:
.../?utm_source=linkedin&utm_medium=social_organic&utm_campaign=data_automation_webinarPartner Newsletter Link:
.../?utm_source=partner_xyz&utm_medium=email&utm_campaign=data_automation_webinarGoogle Ad Link:
.../?utm_source=google&utm_medium=cpc&utm_campaign=data_automation_webinar
The marketing team has set up "webinar_signup" as a conversion event in GA4. When they look at their campaign report, they aren’t just looking at traffic—they're analyzing which source drove the most conversions. They might find that, despite Google sending the most traffic, the partner newsletter delivered the highest number of qualified signups.
Final Thoughts
Setting up campaign URL tracking turns Google Analytics from a simple traffic counter into a powerful business intelligence tool. By consistently tagging your incoming links with UTM parameters, you remove the ambiguity from your marketing reports and gain a true understanding of what’s driving growth. These insights allow you to double down on what works and cut back on what doesn't, optimizing your budget and getting better results from your efforts.
Connecting all your platforms—from Google Analytics and Shopify to your paid ad channels—is the first step, but digging through separate reports to stitch together a full picture of campaign performance can still feel like a full-time job. With us, that manual reporting drudgery disappears. We centralize all your marketing data, and instead of clicking through different GA4 reports, you can ask in plain English, "Show me a dashboard comparing Facebook Ads spend vs revenue by campaign for the last 30 days." Graphed instantly builds you a live, shareable dashboard, letting you get straight to the insights that matter.