Google Analytics

Campaign tracking with Google Analytics: Which campaigns lead to purchases

Key takeaways
  • Without campaign tagging, visits from newsletters and apps often show up as direct traffic in GA4. UTM parameters let you attribute every click to its campaign.
  • Google recommends always setting utm_source, utm_medium and utm_campaign, plus utm_id and utm_source_platform. Values are case-sensitive.
  • For Google Ads, auto-tagging does the work. If both methods are used, GA4 applies the auto-tagged values for source and medium.
  • GA4 groups visits from ChatGPT, Gemini, Deepseek, Copilot and Grok into a dedicated “AI Assistant” channel; clicks from AI Overviews and AI Mode count as organic search.

Most companies advertise on several channels at once: Google Ads, Meta (Facebook and Instagram), LinkedIn, newsletters. At the end of the month, the question is which campaign brought in ready-to-buy visitors and which just burned budget. Without campaign tracking, Google Analytics can't answer that. It sees visitors arriving but often attributes clicks from a newsletter or social media app to direct traffic or a generic referral.

This article shows how UTM parameters and Google Ads auto-tagging attribute every visit to the right campaign, where to find the results in GA4, and which rules keep your data clean over time.

Campaign tracking shows which campaigns actually deliver

Campaign tracking means adding a label to every link you share outside your website. When someone clicks it, Google Analytics reads the label and knows: this visitor came from the summer newsletter, via the button at the top right.

Without these labels, Google Analytics lumps much of your traffic together. Clicks from email clients or closed apps, often called “dark social,” show up as direct traffic ((direct) / (none)). With tagging, you can see which LinkedIn post generated inquiries, which Facebook post drove clicks but no purchases, and how much of your monthly revenue comes from the newsletter.

Only with this knowledge can you shift budget from campaigns without results to those that sell. Compare the measured results with advertising costs and contribution margins. This makes it easier to judge the profitability of the campaigns.

Three parameters tie every click to its campaign

The technical core consists of UTM parameters (Urchin Tracking Module), which you append to the destination URL. Google recommends always setting utm_source, utm_medium and utm_campaign . If one is missing, your reports show “(not set)”.

Parameter Function Example
utm_source (always set) Source: the platform or sender the visitor comes from facebook, newsletter_mai
utm_medium (always set) Medium: the marketing channel they come through cpc, email, social
utm_campaign (always set) Campaign name: product, season, or promotion sommersale_2026
utm_content (optional) Content: distinguishes links within the same medium cta_button_top, textlink
utm_term (optional) Term: usually the keyword for paid search outside Google Ads laufschuhe_rot
utm_id (recommended) Campaign ID: links visits to uploaded campaign data such as costs fb_123456789
utm_source_platform (recommended) The platform that drives the visit, such as the buying platform used for budget and targeting search_ads_360

Here's what a finished link looks like:

https://www.ihre-seite.de/angebot?utm_source=facebook&utm_medium=social&utm_campaign=sommersale&utm_content=video_variante_a

From this, GA4 reads the source facebook, the medium social, the campaign sommersale and the content video_variante_a.

utm_id is particularly useful if you import cost data from other ad platforms into GA4. Clicks, costs, and revenue per campaign then sit side by side, and you can see which campaigns earn more than they cost.

Typing long UTM strings by hand invites errors. Three approaches make it reliable:

Google's Campaign URL Builder

Google's standard browser-based tool. Enter the destination URL and parameters, then copy the finished link.

A shared spreadsheet for your team

If several people run campaigns, we recommend a shared Google Sheet or Excel file. It defines the allowed spellings, for example only email and never E-Mail or Newsletter as the medium, and a formula builds each link. Otherwise, inconsistent spellings fragment your reports.

Browser extensions

Browser extensions create campaign links right on the landing page. They're handy for one-off links but no substitute for shared naming rules.

Important: UTM parameters belong only on links that point to your website from outside. Never use them on internal links, such as from your blog to your shop. Otherwise, they overwrite the visit's original source, for example Google Ads.

For Google Ads, auto-tagging does the work

For Google Ads, you don't need your own UTM parameters. Auto-tagging appends a click ID (GCLID) to every ad click, and GA4 uses it to add details you could never fully capture yourself, such as ad group, keyword, and search query.

How to set it up:

  1. Linking: In GA4, connect your accounts under Admin > Product links > Google Ads.
  2. Auto-tagging: In your Google Ads account settings, check that it is turned on.

The benefits:

  • Google Ads and GA4 work from the same data, and typos in UTM values disappear.
  • You can import key events from GA4 into Google Ads.
  • You can build remarketing audiences based on behavior in GA4.

Note: If you use both auto-tagging and your own UTM parameters in Google Ads, GA4 uses the automatic values for source, medium, and the other channel dimensions. There is no GA4 setting that gives your UTM values priority. For measuring conversions properly within Google Ads itself, see our article on Google Ads conversion tracking.

Three areas of GA4 for analyzing your campaigns

The “User acquisition” report

Path: Reports > Acquisition > User acquisition

This shows which campaign first brought a user to your website, which matters for new customer acquisition.

The “Traffic acquisition” report

Path: Reports > Acquisition > Traffic acquisition

This shows the source of each session, the standard view for campaign analysis:

  • Set the primary dimension to Session source/medium.
  • Click the plus sign to add the secondary dimension Session campaign.

The “Advertising” section

Path: Advertising in the left menu

This section is often overlooked. Attribution paths show how campaigns work together, for example a first touch via Facebook followed by a purchase via Google Ads. Attribution models let you compare how much credit each campaign receives under different models.

Four rules keep your campaign data clean over time

  • Always use lowercase: GA4 distinguishes between Email and email. Make lowercase mandatory for all values.
  • Align media with the default channels: GA4 assigns visits to default channels based on fixed rules. Use email for newsletters, social as the medium for organic posts (not fb or insta), and cpc or paid_social for paid ads. Anything else ends up under “Unassigned”.
  • No spaces: Use underscores or hyphens. sommer kampagne becomes sommer%20kampagnein the URL, which is hard to read and prone to errors.
  • Descriptive names: utm_campaign=c1 will mean nothing to anyone a year from now; utm_campaign=sommersale_2026 will.

Four mistakes we see in audits again and again

Source and medium swapped

  • Wrong: utm_source=email and utm_medium=newsletter
  • Right: utm_source=newsletter_juni and utm_medium=email

The medium is the channel: the how. The source is the specific sender: the where from.

Never add UTM parameters to homepage banners that link to product pages. They overwrite the source the visitor originally came from and distort attribution.

Ignoring “(not set)”

If campaigns often show (not set), parameters are missing, they are misspelled (utm_camapign instead of utm_campaign), or the link to Google Ads is broken.

Personal data in the URL

Never put names, email addresses, or internal project details into UTM parameters. They are visible to anyone in the address bar and end up in your analytics data.

GA4 now gives AI search traffic its own channels

More and more visitors arrive at websites via AI answers. GA4 distinguishes between:

  • AI assistants: GA4 identifies visits from ChatGPT, Gemini, Deepseek, Copilot, or Grok by their referrer, sets the medium ai-assistant and groups them in the default channel AI Assistant . Don't use this medium for your own campaigns.
  • Google AI Overviews and AI Mode: Clicks from these count as Organic Search.

If you advertise in AI environments, for example with ads in ChatGPT, tag those links with UTM parameters like any other paid campaign, using a paid medium such as cpc. That way, you can separate paid and unpaid visits from the same source.

Conclusion: campaign tracking turns assumptions into decisions

Campaign tracking is the difference between “We think this works” and “We know it works.” It takes discipline at the start to tag every newsletter and social link consistently. The effort pays off.

You get clear data, allocate budget based on results, and can show leadership or clients exactly what each campaign contributes. Add costs and margin, and you see which campaigns are profitable.

Initial consultation

Let's find out where your budget can work harder.

A one-on-one conversation where we assess your current position together.

Julia Bühler

Julia Bühler · Solution Manager

Your inquiry comes directly to me. Then pick a time that suits you.

Schedule a consultation

In a first call, we pinpoint where your online marketing has the most profit potential.

Next, you choose a time for your appointment.