A single product page, blog post, or listing can end up reachable through more URLs than you'd expect: with and without a trailing slash, with tracking parameters appended, through both http:// and https://, or duplicated across a www and non-www version of your domain. To a person browsing, these all look like the same page. To a search engine crawling your site, they're technically distinct URLs -- and that's a problem worth fixing.
Why duplicate URLs actually hurt you
When a search engine finds the same content at multiple URLs, it has to guess which one to show in results and which ones to treat as duplicates. That guess doesn't always go the way you'd want. Worse, any ranking signals -- links pointing at your content, engagement metrics -- get split across the different URL variants instead of consolidating behind one page. A page that could rank well on its own sometimes underperforms simply because its authority is scattered across three or four near-identical URLs.
What a canonical tag does
A canonical tag is a line in a page's <head> that looks like this:
<link rel="canonical" href="https://example.com/product/blue-shoes">
It's a signal, not a redirect -- the page at /product/blue-shoes?ref=email still loads normally, but the tag tells crawlers "treat this URL as the authoritative version, and consolidate ranking signals there." Every indexable page on your site should have a canonical tag, even if it just points to itself -- that removes any ambiguity about which version is the real one.
Common situations where this actually matters
The most frequent cause is URL parameters: session IDs, sort orders, or marketing tags like utm_source appended to an otherwise identical page. E-commerce sites hit this constantly when the same product is filterable by color or size through the URL. Another common case is syndicated or cross-posted content -- if your article also runs on a partner site, the canonical tag on their copy should point back to your original, so you get credit for it rather than competing with your own content.
What a canonical tag is not a substitute for is a 301 redirect. If a URL is genuinely obsolete and you want visitors and crawlers permanently sent elsewhere, redirect it. Canonicalization is for cases where multiple valid URLs need to keep working but you still want one clear "main" version for search engines to index.
Setting it up without hand-writing HTML
Getting the tag syntax exactly right, and remembering it on every page template, is easy to get wrong at scale. The Canonical URL Generator takes your target URL and outputs the correctly formatted <link> tag, ready to drop into your page head -- no need to second-guess the attribute order or quoting.