Validate UTM campaign naming conventions
Check a campaign name such as summer-sale-q3 against the naming convention your team chose and see which rules pass or fail, so a stray capital or space never splits your analytics reports. Free in your browser.
- Free
- Runs in your browser
- No sign-up
- Your data stays on your device
Run — free
Worked example
- Campaign name
- summer-sale-q3
- Pattern
- lowercase-hyphenated-by-quarter
- Expected
- lowercase hyphenated text ending in q1, q2, q3, or q4
A consistent UTM campaign name keeps analytics reports searchable, comparable, and easy to govern. This validator checks one campaign name against an explicitly selected convention and explains which rules pass or fail. Choose a supported pattern for lowercase hyphenated names, quarter suffixes, underscore-separated names, uppercase names, or compact alphanumeric identifiers. The result is deterministic, so the same name and pattern always produce the same answer. Use it before publishing a link, inside a campaign review checklist, or as a guard in an automated URL-building workflow.
Choose a convention that matches your reporting system
A naming convention is useful only when every contributor can apply it without guessing. Start by selecting the supported pattern that reflects the rule your team has documented. The lowercase-hyphenated pattern accepts names such as spring-launch and partner-webinar-2026.
It rejects spaces, underscores, uppercase letters, doubled separators, and punctuation. Choose lowercase-hyphenated-by-quarter when every name must end with q1, q2, q3, or q4, as in summer-sale-q3. The uppercase-hyphenated option serves established taxonomies such as EMEA-PRODUCT-Q4, while alphanumeric is intentionally strict and allows no separator at all.
Supplying the pattern is mandatory because a campaign name cannot be judged in isolation: summer-sale and SUMMER-SALE may each be correct under different governance rules. Make the chosen pattern part of the campaign brief, link builder, or form configuration so reviewers evaluate the same written standard rather than relying on personal preference. This also prevents a silent default from approving names under a convention that the team never intended to use.
Read the validation result and correct failures
The response includes the submitted campaign name, the normalized pattern name, an overall valid flag, a list of checks, a list of violations, and a short description of the expected format. A valid result means the complete name matches every requirement of the selected convention. A false result is deliberately more informative than a generic rejection.
For example, Summer-Sale-Q3 checked against lowercase-hyphenated-by-quarter fails the lowercase check and the quarter suffix check because the convention requires a lowercase q. A name with spaces fails the separator check, while a name ending in q5 fails the allowed quarter range. Use the violations array for concise interface messages or automated decisions, and use the checks array when a reviewer needs to see both successful and unsuccessful rules.
The validator trims surrounding whitespace before evaluation, but it does not rewrite the campaign name or guess a replacement. That behavior protects reporting identifiers from unreviewed changes. Correct the source value, run validation again, and publish only after valid becomes true.
Put validation before links enter circulation
The best place to validate a UTM campaign name is immediately before a tracking URL is generated or approved. In a campaign form, run the check when the author leaves the campaign-name field and show the failed rules beside that field. In a release pipeline, treat valid false as a review failure before URLs are copied into advertisements, newsletters, social posts, QR codes, or partner materials.
Store the selected pattern alongside internal campaign standards so future checks reproduce the original decision. The service performs bounded local string checks without network lookups, random choices, or time-dependent rules, making its results stable in tests and production.
What you can do with it
Review a quarterly launch
Require a lowercase q1 through q4 suffix so campaign reports group cleanly by planned quarter.
Check an automated link workflow
Validate generated campaign identifiers before distributing URLs through ads, email, social, or partners.
FAQ
Which patterns are supported?
Supported values are lowercase-hyphenated-by-quarter, lowercase-hyphenated, lowercase-underscore-separated, uppercase-hyphenated, and alphanumeric.
Does the validator fix an invalid name?
No. It reports failed rules without silently changing an analytics identifier that may require human approval.
Are quarter suffixes case-sensitive?
Yes. The lowercase-hyphenated-by-quarter convention requires a final lowercase q followed by 1, 2, 3, or 4.
Why must I choose a convention before checking a name?
Because a name cannot be judged on its own: summer-sale and SUMMER-SALE can each be correct under different team rules. Requiring the convention means no silent default ever approves a name under a rule you never meant to use.
Why check the campaign name before sharing the link?
Because changing the name after the link is out splits your measurements into separate values. Even a harmless difference in capitalization creates another row in your reports, so the best moment to check is right before the tracking link is built.
Related tools
For developers — API access
Everything on this page is available programmatically. This section is for teams who want to wire it into their own systems; everyone else can just use the tool above.
API endpoint
Prefer to automate it? One authenticated POST creates the task; the result comes back by webhook or a signed link. The same capability also runs here on the web, by email and from Telegram — and soon from our app too.
Call it from your stack
curl -X POST https://api.kit.forhosting.com/seo/utm-campaign-name-validate \
-H "Authorization: Bearer $KIT_KEY" \
-H "Content-Type: application/json" \
-d '{"campaign_name":"summer-sale-q3","pattern":"lowercase-hyphenated-by-quarter"}'const res = await fetch("https://api.kit.forhosting.com/seo/utm-campaign-name-validate", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.KIT_KEY}`,
"Content-Type": "application/json"
},
body: JSON.stringify({
"campaign_name": "summer-sale-q3",
"pattern": "lowercase-hyphenated-by-quarter"
})
});
const { task_id } = await res.json();import os, requests
res = requests.post(
"https://api.kit.forhosting.com/seo/utm-campaign-name-validate",
headers={"Authorization": f"Bearer {os.environ['KIT_KEY']}"},
json={
"campaign_name": "summer-sale-q3",
"pattern": "lowercase-hyphenated-by-quarter"
},
)
task_id = res.json()["task_id"]<?php
$res = file_get_contents("https://api.kit.forhosting.com/seo/utm-campaign-name-validate", false, stream_context_create([
"http" => [
"method" => "POST",
"header" => "Authorization: Bearer " . getenv("KIT_KEY") . "\r\nContent-Type: application/json",
"content" => '{"campaign_name":"summer-sale-q3","pattern":"lowercase-hyphenated-by-quarter"}',
],
]));
$task = json_decode($res, true);body := bytes.NewBufferString(`{"campaign_name":"summer-sale-q3","pattern":"lowercase-hyphenated-by-quarter"}`)
req, _ := http.NewRequest("POST", "https://api.kit.forhosting.com/seo/utm-campaign-name-validate", body)
req.Header.Set("Authorization", "Bearer "+os.Getenv("KIT_KEY"))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)Example request
{
"campaign_name": "summer-sale-q3",
"pattern": "lowercase-hyphenated-by-quarter"
}Example response
{
"task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
"type": "seo.utm_campaign_name_validate",
"status": "queued",
"_links": {
"result": "/tasks/tsk_…/result"
}
}The API is asynchronous: the call returns a task_id immediately and the result arrives by webhook. Polling is capped at 1 req/s per task.
Pricing
Published price — no tokens, no invented credits. A failed task is never charged.
Errors
| HTTP | Code | Meaning |
|---|---|---|
401 | unauthorized | Missing or invalid API key. |
402 | insufficient_balance | Your balance doesn't cover the task price. |
404 | unknown_type | That task type doesn't exist. |
429 | rate_limited | Too many requests. Use the webhook instead of polling. |
Technical notes
Choose a convention that matches your reporting system
For systems that already use snake-style identifiers, lowercase-underscore-separated accepts forms such as lifecycle_email_q2.
Read the validation result and correct failures
If the pattern itself is missing, empty, or unsupported, the request returns an input error instead of pretending that a default convention applies.
Put validation before links enter circulation
In a spreadsheet or bulk workflow, call the API once for each proposed name and route invalid rows back to their owners. Early validation matters because changing utm_campaign after distribution fragments measurements into separate analytics values; even a harmless difference in capitalization can create another row in reports. Browser use is available for quick manual checks, while API requests cost $0.002 each for automation. This validator addresses the campaign-name component only: it does not build a URL, verify that a destination resolves, or decide whether a taxonomy is strategically useful.
Integration use cases
Guard a campaign form
Reject inconsistent utm_campaign values before a marketer can publish or export a tracking link.
Technical questions
What happens if I omit the pattern?
The request returns an invalid_input error because validation requires an explicit naming convention.
How much does an API validation cost?
Each API request costs $0.002. You can also run the validator in the browser for a quick manual check.