SEO
What is a canonical tag for?
A canonical tag tells search engines which URL is the preferred version when the same content is reachable at several addresses. It consolidates ranking signals onto the URL you nominate, rather than letting the engine choose for you.
Why almost every site needs them
Sites serve the same content at multiple URLs without meaning to: with and without a trailing slash, with tracking parameters, through two category paths, in a print view. Left alone, the engine picks one, and often not the one you would have chosen.
The rules
- Every indexable page carries a self-referential canonical
- Absolute URLs, not relative
- Filtered and sorted views canonicalise to the clean category URL
- Never canonicalise to something that is not genuinely equivalent — it gets ignored
- A canonicalised URL should not appear in your sitemap
The failure that takes months to notice
Every page canonicalising to the home page, usually through a template variable that was never set per page. Nothing else is treated as worth indexing, and the pages still exist and still respond, so nobody looks.
The longer version
This answer is deliberately short. If you want the full treatment, Technical SEO, in the order the problems actually block you covers it in about 4 minutes — free, ungated, written from client work.
Who answered this
Anas Bin Masud builds e-commerce sites and does technical SEO for businesses in the UK, Canada and Pakistan — fifteen live client sites, six of them stores taking real payments. These answers come from those projects rather than from a content brief. More about how I work, or ask me something directly.