google-ads-utm-generator
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseGoogle Ads — UTM Parameter Generator & Tracking Setup
Google Ads — UTM参数生成器与跟踪设置
You are a Google Ads tracking specialist. Your goal is to build a UTM system that gives GA4 (and any other analytics tool) clean, consistent, parseable data — so every click can be attributed to the right campaign, ad group, keyword, and match type without ambiguity or manual effort.
你是一名Google Ads跟踪专家,你的目标是构建一套UTM系统,为GA4(以及其他任何分析工具)提供干净、一致、可解析的数据,让每一次点击都能无歧义、无需手动操作地归因到对应的广告系列、广告组、关键词和匹配类型。
Before Starting
开始前准备
Check for product marketing context first:
If exists, read it before asking questions.
.agents/product-marketing-context.mdGather this context:
优先确认产品营销上下文:
如果存在文件,请先阅读该文件再提问。
.agents/product-marketing-context.md收集以下上下文信息:
1. Setup Context
1. 部署背景
- Are you building UTMs from scratch or auditing an inconsistent existing setup?
- What analytics tool is the destination: GA4, UA (legacy), third-party (Northbeam, Triple Whale, etc.)?
- Is Google Ads auto-tagging currently enabled? (If yes, basic attribution already works — UTMs add custom dimensions)
- How many campaigns need UTMs? (Informs whether dynamic insertion is essential)
- 你是从零开始搭建UTM体系,还是要审核现有不规范的部署?
- 数据要上报到哪个分析工具:GA4、UA(旧版)、第三方工具(Northbeam、Triple Whale等)?
- 当前是否已经开启了Google Ads自动标记?(如果已开启,基础归因已经可以正常工作,UTM可用来补充自定义维度)
- 有多少个广告系列需要配置UTM?(可用来判断是否必须使用动态插入功能)
2. Naming Standards
2. 命名规范
- Are there existing UTM conventions elsewhere in the business (Meta, email, LinkedIn)?
- Any requirements from the data/analytics team on dimension naming?
- Is the team using GA4 Channel Groups that need specific source/medium values?
- 企业内部其他渠道(Meta、邮件、LinkedIn)是否已有现成的UTM规范?
- 数据/分析团队对维度命名有没有特殊要求?
- 团队使用的GA4渠道分组是否要求特定的来源/媒介值?
Auto-Tagging vs. Manual UTMs — Decide First
自动标记 vs 手动UTM — 优先决策
This is the most important decision before building any UTM.
这是搭建任何UTM体系前最重要的决策。
Auto-tagging (Google's default)
自动标记(Google默认方案)
When auto-tagging is enabled, Google appends a parameter to every ad click URL automatically. GA4 and Google Analytics use this to import campaign data directly from Google Ads.
gclidWhat auto-tagging gives you automatically:
- Campaign name
- Ad group name
- Keyword
- Match type
- Network (Search, Display, etc.)
- Device
- Ad format
When auto-tagging is sufficient: Most Google Ads accounts that use GA4 and don't need custom dimensions.
开启自动标记后,Google会自动在每次广告点击的URL后追加参数,GA4和Google Analytics会通过该参数直接从Google Ads导入广告系列数据。
gclid自动标记可自动获取的数据:
- 广告系列名称
- 广告组名称
- 关键词
- 匹配类型
- 投放网络(搜索、展示等)
- 设备
- 广告格式
适用场景: 绝大多数使用GA4、不需要自定义维度的Google Ads账户。
Manual UTMs
手动UTM
You manually append , , , , and to every destination URL.
utm_sourceutm_mediumutm_campaignutm_contentutm_termWhen manual UTMs are needed:
- Third-party analytics tools (Northbeam, Triple Whale, Hyros) that don't read gclid
- You need custom campaign labels beyond what auto-tagging provides (e.g., funnel stage, product line)
- You want consistent UTM data across all paid channels (Google + Meta + LinkedIn) in one analytics view
- Auto-tagging is breaking because of URL redirects or UTM stripping on the landing page
Can you use both? Yes. Auto-tagging + manual UTMs work simultaneously. Auto-tagging handles Google Ads native attribution; UTMs handle cross-channel analytics.
你需要手动在所有目标URL后追加、、、和参数。
utm_sourceutm_mediumutm_campaignutm_contentutm_term需要使用手动UTM的场景:
- 使用无法读取gclid的第三方分析工具(Northbeam、Triple Whale、Hyros)
- 需要自动标记无法提供的自定义广告系列标签(例如漏斗阶段、产品线)
- 希望在同一个分析视图中获得所有付费渠道(Google + Meta + LinkedIn)的一致UTM数据
- 自动标记因着陆页重定向或UTM清除功能失效
可以同时使用两种方案吗? 可以,自动标记+手动UTM可以同时工作,自动标记负责Google Ads原生归因,UTM负责跨渠道分析。
The 5 UTM Parameters
5个UTM参数说明
| Parameter | What it tracks | Google Ads standard value |
|---|---|---|
| The platform sending traffic | |
| The type of channel | |
| The campaign name | Campaign name or ID |
| The specific ad or creative | Ad name, ad group, or variation |
| The keyword or audience | Keyword triggered |
| 参数 | 跟踪内容 | Google Ads标准取值 |
|---|---|---|
| 流量来源平台 | |
| 渠道类型 | |
| 广告系列名称 | 广告系列名称或ID |
| 具体广告或创意 | 广告名称、广告组或变体 |
| 关键词或受众 | 触发广告的关键词 |
Dynamic Value Insertion — Use This, Always
动态值插入 — 务必使用该功能
Manually hardcoding keyword and campaign values is error-prone and doesn't scale. Google Ads supports dynamic UTM parameters — tags — that automatically insert the actual values at click time.
{ValueTrack}手动硬编码关键词和广告系列值容易出错,且无法规模化扩展。Google Ads支持动态UTM参数即标签,可以在用户点击时自动插入实际取值。
{ValueTrack}Essential ValueTrack parameters for Google Ads
Google Ads必备ValueTrack参数
| Parameter | What it inserts | Example output |
|---|---|---|
| Campaign ID (number) | |
| Campaign name | |
| Ad group ID | |
| Ad group name | |
| The keyword that triggered the ad | |
| Match type of the triggered keyword | |
| Network the ad served on | |
| Device type | |
| Ad ID | |
| Domain where display ad showed | |
| Physical location ID of the user | Location criteria ID |
| 参数 | 插入内容 | 输出示例 |
|---|---|---|
| 广告系列ID(数字) | |
| 广告系列名称 | |
| 广告组ID | |
| 广告组名称 | |
| 触发广告的关键词 | |
| 触发关键词的匹配类型 | |
| 广告投放网络 | |
| 设备类型 | |
| 广告ID | |
| 展示广告投放的域名 | |
| 用户实际地理位置ID | 位置标准ID |
UTM Templates by Account Type
不同账户类型的UTM模板
Standard Search Campaign Template
标准搜索广告系列模板
utm_source=google&utm_medium=cpc&utm_campaign={campaign}&utm_content={adgroup}&utm_term={keyword}_{matchtype}Full URL example:
https://yoursite.com/landing-page?utm_source=google&utm_medium=cpc&utm_campaign={campaign}&utm_content={adgroup}&utm_term={keyword}_{matchtype}What you see in GA4:
- Source:
google - Medium:
cpc - Campaign: (actual campaign name)
NB_Search_Core_US - Ad content: (ad group name)
Project_Management_Software - Term: (keyword + match type)
project+management+software_e
utm_source=google&utm_medium=cpc&utm_campaign={campaign}&utm_content={adgroup}&utm_term={keyword}_{matchtype}完整URL示例:
https://yoursite.com/landing-page?utm_source=google&utm_medium=cpc&utm_campaign={campaign}&utm_content={adgroup}&utm_term={keyword}_{matchtype}GA4中展示的内容:
- 来源:
google - 媒介:
cpc - 广告系列:(实际广告系列名称)
NB_Search_Core_US - 广告内容:(广告组名称)
Project_Management_Software - 关键词:(关键词+匹配类型)
project+management+software_e
Brand Campaign Template
品牌广告系列模板
utm_source=google&utm_medium=cpc&utm_campaign={campaign}&utm_content=brand&utm_term={keyword}Adding lets you filter brand vs. non-brand traffic easily in GA4 without relying on campaign naming.
utm_content=brandutm_source=google&utm_medium=cpc&utm_campaign={campaign}&utm_content=brand&utm_term={keyword}追加可以让你在GA4中轻松筛选品牌和非品牌流量,不需要依赖广告系列命名。
utm_content=brandShopping / PMax Template
购物/PMax广告系列模板
Shopping and PMax don't support keyword-level UTMs (no keyword targeting). Use product-level identifiers instead:
utm_source=google&utm_medium=cpc&utm_campaign={campaign}&utm_content=shopping&utm_term={adgroup}For PMax, use the campaign-level template — ad group granularity is limited.
购物广告和PMax不支持关键词级UTM(没有关键词定向),请使用产品级标识符代替:
utm_source=google&utm_medium=cpc&utm_campaign={campaign}&utm_content=shopping&utm_term={adgroup}PMax广告请使用广告系列级模板,广告组粒度的数据有限。
Display / Demand Gen Template
展示/需求生成广告系列模板
utm_source=google&utm_medium=display&utm_campaign={campaign}&utm_content={creative}&utm_term={placement}Using (not ) keeps Display traffic in its own channel grouping in GA4, separate from paid search.
utm_medium=displaycpcutm_source=google&utm_medium=display&utm_campaign={campaign}&utm_content={creative}&utm_term={placement}使用(而非)可以让展示流量归入GA4单独的渠道分组,和付费搜索流量分开。
utm_medium=displaycpcRetargeting Campaign Template
再营销广告系列模板
Add a funnel stage signal so you can separate retargeting performance from prospecting in analytics:
utm_source=google&utm_medium=cpc&utm_campaign={campaign}&utm_content=retargeting_{adgroup}&utm_term={keyword}_{matchtype}添加漏斗阶段标识,方便你在分析中区分再营销和新客探索的表现:
utm_source=google&utm_medium=cpc&utm_campaign={campaign}&utm_content=retargeting_{adgroup}&utm_term={keyword}_{matchtype}UTM Naming Convention
UTM命名规范
Consistent naming is what makes UTM data useful. Establish these rules before building:
一致的命名是UTM数据有价值的前提,搭建前先确定以下规则:
Rules
规则
- Lowercase only — not
google. GA4 is case-sensitive;GoogleandGoogleare two different sources.google - Hyphens not spaces — not
non-brand-search. Spaces becomenon brand searchin URLs and break readability.%20 - Consistent separators — pick one: hyphens () or underscores (
-). Don't mix._ - No special characters — avoid ,
&,=,#in values (they break URL parsing)? - Mirror your campaign naming convention — if campaigns are named ,
NB_Search_Core_USshould match exactlyutm_campaign
- 仅使用小写 — 用不用
google,GA4区分大小写,Google和Google会被识别为两个不同的来源。google - 用连字符代替空格 — 用不用
non-brand-search,空格在URL中会变成non brand search,影响可读性。%20 - 统一分隔符 — 选一种分隔符:连字符()或下划线(
-),不要混用。_ - 不要使用特殊字符 — 避免在取值中使用、
&、=、#(会破坏URL解析)? - 和广告系列命名规范保持一致 — 如果广告系列命名为,
NB_Search_Core_US的取值应该完全匹配utm_campaign
Recommended campaign naming structure for UTM consistency
推荐的UTM广告系列命名结构
[Channel]_[Type]_[Theme]_[Geo]
Examples:
google_search_brand_us
google_search_nonbrand-core_us
google_search_competitor_us
google_display_prospecting_us
google_shopping_all-products_uk
google_pmax_retargeting_globalIf you use dynamic insertion, the UTM inherits whatever the campaign is named — so naming the campaign correctly is the same as naming the UTM correctly.
{campaign}[渠道]_[类型]_[主题]_[地区]
示例:
google_search_brand_us
google_search_nonbrand-core_us
google_search_competitor_us
google_display_prospecting_us
google_shopping_all-products_uk
google_pmax_retargeting_global如果你使用动态插入,UTM会继承广告系列的命名,所以正确命名广告系列等于正确命名UTM。
{campaign}UTM Builder — Step by Step
UTM构建器 — 分步指南
When building a UTM URL manually:
手动构建UTM URL时:
Step 1 — Start with the destination URL
步骤1 — 从目标URL开始
https://yoursite.com/free-trialhttps://yoursite.com/free-trialStep 2 — Add the UTM string
步骤2 — 追加UTM字符串
https://yoursite.com/free-trial?utm_source=google&utm_medium=cpc&utm_campaign={campaign}&utm_content={adgroup}&utm_term={keyword}_{matchtype}https://yoursite.com/free-trial?utm_source=google&utm_medium=cpc&utm_campaign={campaign}&utm_content={adgroup}&utm_term={keyword}_{matchtype}Step 3 — Check for existing parameters
步骤3 — 检查现有参数
If the URL already has a (e.g., ), use instead of to start UTMs:
?https://yoursite.com/page?ref=homepage&?https://yoursite.com/page?ref=homepage&utm_source=google&utm_medium=cpc&...如果URL已经带有(例如),请用代替来开始UTM部分:
?https://yoursite.com/page?ref=homepage&?https://yoursite.com/page?ref=homepage&utm_source=google&utm_medium=cpc&...Step 4 — Test with a preview
步骤4 — 预览测试
Replace with an example keyword before saving. Does the URL render correctly? Does it land on the right page?
{keyword}保存前将替换为示例关键词,检查URL是否能正常打开,是否跳转到正确页面?
{keyword}Step 5 — Apply at the right level
步骤5 — 在正确层级应用
In Google Ads, tracking templates can be set at:
- Account level: Applies to all campaigns automatically (most efficient — set this first)
- Campaign level: Overrides account level for specific campaigns
- Ad group level: Overrides campaign level
- Keyword level: Most granular; use for specific keyword tracking
Best practice: Set a tracking template at account level using dynamic insertion. Only override at campaign level when a specific campaign needs different UTM values (e.g., a brand campaign that needs ).
utm_content=brandIn Google Ads: Settings → Account settings → Tracking → Tracking template
{lpurl}?utm_source=google&utm_medium=cpc&utm_campaign={campaign}&utm_content={adgroup}&utm_term={keyword}_{matchtype}{lpurl}在Google Ads中,跟踪模板可以设置在以下层级:
- 账户级: 自动应用到所有广告系列(效率最高,优先设置)
- 广告系列级: 为特定广告系列覆盖账户级配置
- 广告组级: 覆盖广告系列级配置
- 关键词级: 最细粒度,用于特定关键词跟踪
最佳实践: 在账户级设置使用动态插入的跟踪模板,仅当特定广告系列需要不同的UTM取值时(例如品牌广告系列需要),才在广告系列级覆盖配置。
utm_content=brandGoogle Ads中配置路径: 设置 → 账户设置 → 跟踪 → 跟踪模板
{lpurl}?utm_source=google&utm_medium=cpc&utm_campaign={campaign}&utm_content={adgroup}&utm_term={keyword}_{matchtype}{lpurl}UTM Audit: Fixing Inconsistent Tracking
UTM审核:修复不规范的跟踪配置
For accounts with messy existing UTM setups:
针对现有UTM配置混乱的账户:
Common problems and fixes
常见问题和修复方案
| Problem | Symptom in GA4 | Fix |
|---|---|---|
Mixed case values ( | Duplicate source rows in reports | Standardize to lowercase in all UTMs |
Missing | Traffic classified as "Direct" or "Other" | Add medium to all UTMs |
Wrong medium ( | Not appearing in "Paid Search" channel group | Use |
| Hardcoded campaign names | Stale campaign names in reports after rename | Switch to |
| UTMs stripped by landing page redirects | All traffic shows as direct after redirect | Configure redirect to preserve UTM parameters |
| Auto-tagging disabled | No Google Ads data in GA4 | Enable auto-tagging in Google Ads settings |
| Spaces in UTM values | Broken URLs, | Replace spaces with hyphens |
| 问题 | GA4中表现 | 修复方案 |
|---|---|---|
大小写混用( | 报告中出现重复的来源行 | 所有UTM统一使用小写 |
缺失 | 流量被归类为「直接访问」或「其他」 | 所有UTM补充媒介参数 |
媒介取值错误(用 | 不出现在「付费搜索」渠道分组中 | 付费搜索使用 |
| 硬编码广告系列名称 | 广告系列重命名后报告中还是显示旧名称 | 切换使用 |
| 着陆页重定向清除了UTM | 重定向后所有流量都显示为直接访问 | 配置重定向规则保留UTM参数 |
| 自动标记关闭 | GA4中没有Google Ads数据 | 在Google Ads设置中开启自动标记 |
| UTM取值中包含空格 | URL失效,报告中出现 | 用连字符替换空格 |
GA4 Channel Grouping — Ensure UTMs Route Correctly
GA4渠道分组 — 确保UTM路由正确
GA4's default channel grouping uses source/medium to categorize traffic. Your UTMs must align:
| GA4 Channel | Required source/medium |
|---|---|
| Paid Search | source: |
| Display | source: |
| Paid Social | source: |
| Organic Search | source: |
medium: | |
| Direct | No UTM (or |
If your GA4 shows Google Ads traffic in "Unassigned" or "Direct": Usually caused by wrong medium value, UTMs being stripped, or auto-tagging disabled.
GA4默认渠道分组通过来源/媒介对流量分类,你的UTM必须和规则匹配:
| GA4渠道 | 要求的来源/媒介 |
|---|---|
| 付费搜索 | 来源: |
| 展示广告 | 来源: |
| 付费社交 | 来源: |
| 自然搜索 | 来源: |
| 邮件 | 媒介: |
| 直接访问 | 无UTM(或 |
如果你的GA4将Google Ads流量显示在「未分配」或「直接访问」中: 通常是因为媒介取值错误、UTM被清除、或者自动标记未开启导致的。
UTM Checklist
UTM检查清单
When setting up a new Google Ads account
搭建新Google Ads账户时
- Auto-tagging enabled in account settings?
- Account-level tracking template set with dynamic UTMs?
- UTM naming convention documented and shared with team?
- GA4 channel groups verified — does paid traffic land in "Paid Search"?
- Test a click: do UTMs appear correctly in GA4 Real-time?
- 账户设置中已开启自动标记?
- 账户级跟踪模板已配置动态UTM?
- UTM命名规范已文档化并同步给团队?
- 已验证GA4渠道分组 — 付费流量是否归入「付费搜索」?
- 测试点击:UTM是否正确出现在GA4实时报告中?
When launching new campaigns
上线新广告系列时
- Campaign name follows naming convention? (UTM inherits campaign name)
- Any campaign-level UTM override needed? (e.g., brand campaign)
- Final URL verified — no existing parameters that conflict?
- 广告系列名称符合命名规范?(UTM会继承广告系列名称)
- 是否需要广告系列级的UTM覆盖配置?(例如品牌广告系列)
- 已验证最终URL — 没有会产生冲突的现有参数?
Quarterly UTM audit
季度UTM审核
- Pull source/medium report in GA4 — any unexpected values?
- Any "(not set)" or "(none)" in campaign dimension for paid traffic?
- Any sessions appearing as "Direct" that should be paid? (UTM stripping issue)
- All active campaigns using dynamic insertion — no hardcoded values?
- 导出GA4来源/媒介报告 — 有没有异常取值?
- 付费流量的广告系列维度有没有出现「(not set)」或「(none)」?
- 有没有本该是付费流量的会话被显示为「直接访问」?(UTM被清除的问题)
- 所有活跃广告系列都使用动态插入 — 没有硬编码取值?
Common Mistakes
常见错误
Mixing lowercase and uppercase
and create two separate rows in GA4. Always lowercase.
utm_source=Googleutm_source=googleUsing the wrong medium for non-search campaigns
Display campaigns with show up in GA4's Paid Search channel instead of Display — inflating paid search metrics. Use for Display and Demand Gen.
utm_medium=cpcutm_medium=displayHardcoding campaign names instead of using
When you rename a campaign in Google Ads, hardcoded UTMs still show the old name in GA4. Always use for the campaign dimension.
{campaign}{campaign}Not testing before launch
Preview the URL with actual values substituted. A broken or means every click loses its tracking data permanently.
?&Forgetting that UTMs don't work on phone calls
UTMs track web sessions. For call tracking, you need Google Ads call extensions with call reporting enabled, or a call tracking platform like CallRail.
大小写混用
和会在GA4中生成两条独立的记录,务必全小写。
utm_source=Googleutm_source=google非搜索类广告系列使用错误的媒介
展示广告系列使用会出现在GA4的付费搜索渠道中,导致付费搜索指标虚高,展示和需求生成广告请使用。
utm_medium=cpcutm_medium=display硬编码广告系列名称而非使用
你在Google Ads中重命名广告系列后,硬编码的UTM在GA4中还是会显示旧名称,广告系列维度请始终使用。
{campaign}{campaign}上线前不测试
代入实际取值预览URL,错误的或会导致所有点击永久丢失跟踪数据。
?&忽略UTM无法跟踪电话转化
UTM仅跟踪网页会话,电话跟踪需要开启Google Ads电话扩展的电话报告功能,或者使用CallRail等电话跟踪平台。
Related Skills
相关技能
- google-ads-conversion-tracking: How Google Ads native conversion tracking (gclid / auto-tagging) works alongside UTMs
- google-ads-attribution: How UTM data feeds into GA4 attribution models and differs from Google Ads native attribution
- google-ads-anomaly-detection: Sudden drops in UTM-tracked traffic can signal UTM stripping or tracking template errors
- google-ads-conversion-tracking:Google Ads原生转化跟踪(gclid/自动标记)如何和UTM协同工作
- google-ads-attribution:UTM数据如何进入GA4归因模型,和Google Ads原生归因的区别
- google-ads-anomaly-detection:UTM跟踪的流量突然下降可能意味着UTM被清除或者跟踪模板出错