Most sites generate more URLs than they have unique pieces of content — a product reachable via three category paths, a page with and without a tracking parameter, an HTTP and HTTPS version left live during a migration. A canonical tag, placed in the <head> as <link rel="canonical" href="https://example.com/preferred-url">, tells a search engine "index the URL in this tag, not the one you fetched." Duplicate content doesn't get penalized so much as it gets diluted: links and signals pointed at three near-identical URLs would otherwise rank weaker than the same signals concentrated on one.
Self-referencing vs. cross-domain
Most pages should carry a self-referencing canonical — a URL pointing at itself — as a default hygiene measure, so that any accidental duplicate (a stray parameter, a trailing slash variant) resolves back to the clean version automatically. A cross-domain canonical points to a URL on a different domain entirely, and is the standard mechanism for syndicated content: if example.com republishes a partner's article, its canonical should point back to the original, telling engines not to compete with the source for rankings.
Where canonicals quietly break
- Canonical points to a redirect. If the canonical target itself 301s somewhere else, the crawler now has to follow a hop to find the real destination — resolve the canonical straight to the final URL instead. See HTTP status codes for what each hop actually signals.
- Canonical chains. Page A canonicalizes to B, which canonicalizes to C. Search engines will try to resolve the chain, but there's no guarantee they pick the URL you intended — collapse every chain so each page points directly at the true final URL.
- Conflicting signals. A canonical pointing at URL B while the sitemap, internal links, and hreflang tags all point at URL A. Engines treat canonical as a strong hint, not a directive — the more the surrounding signals agree with it, the more likely it's honored.
- Cross-domain canonical used by mistake. Pointing a canonical at a competitor's domain (a leftover from a copy-pasted template) tells search engines your own page isn't the original — checked rarely, and costly when it's wrong.
Because canonical tags live in page source and never render visibly, mismatches accumulate silently across a large site — a template change six months ago can leave thousands of pages canonicalizing to the wrong URL with nothing on-screen to flag it. RacingRoach's crawler cross-checks canonical, meta-robots, and directive conflicts across every page it visits (see Find what's broken), which is the practical way to catch this at scale rather than by sampling pages by hand.