Canonical URL
The preferred URL of a web page when multiple URLs serve the same or similar content, signaled to search engines via a rel='canonical' link tag.
Also known as: canonical tag, canonical link, rel=canonical
A canonical URL is the URL a website’s owner designates as the preferred or “official” version of a page when multiple URLs serve the same or similar content. The designation is signaled to search engines via a <link rel="canonical"> tag in the page’s HTML head, telling search engines: “This is the version that should be indexed.”
Canonical URLs help avoid duplicate content issues and consolidate ranking signals to a single URL.
How a canonical tag looks
A canonical tag in the HTML <head>:
<link rel="canonical" href="https://example.com/products/blue-shirt" />
This tag tells search engines that the canonical (preferred) version of the page is https://example.com/products/blue-shirt, regardless of which URL the user actually arrived at.
Why canonical URLs matter
The same content can be reachable through multiple URLs:
https://example.com/products/blue-shirthttp://example.com/products/blue-shirt(HTTP vs HTTPS)https://www.example.com/products/blue-shirt(withwww)https://example.com/products/blue-shirt/(trailing slash)https://example.com/products/blue-shirt?ref=email(tracking parameter)https://example.com/products/blue-shirt?color=blue&size=L(filters)https://example.com/category/shirts/blue-shirt(categorized path)
Without canonicalization, search engines may treat these as separate pages, splitting ranking signals across them. A canonical tag consolidates the signals to one preferred URL.
How search engines use canonical tags
The canonical tag is a hint, not a directive. Google considers it as one signal among many; it can choose a different canonical if other signals (internal links, sitemaps, redirects) strongly suggest otherwise.
Google’s process for choosing a canonical includes:
- The
<link rel="canonical">tag - 301 redirects
- Internal linking patterns
- Sitemap inclusion
- HTTPS vs HTTP
- URL structure (shorter vs longer)
When Google chooses a canonical that disagrees with the page’s tag, it appears in Google Search Console under the “Page indexing” report.
Common canonicalization patterns
Self-referencing canonical
Every page should include a canonical tag pointing to its own URL:
<!-- On https://example.com/about -->
<link rel="canonical" href="https://example.com/about" />
This is good practice even when there are no obvious duplicates; it signals the canonical version explicitly.
Cross-URL canonical
Pointing duplicate URLs to the canonical version:
<!-- On https://example.com/products/blue-shirt?color=blue -->
<link rel="canonical" href="https://example.com/products/blue-shirt" />
Cross-domain canonical
A canonical tag can point to a different domain (used when content is syndicated):
<!-- On https://syndication-partner.com/article -->
<link rel="canonical" href="https://example.com/original-article" />
This tells search engines the original is the preferred version.
Canonical vs 301 redirect
| Aspect | Canonical tag | 301 redirect |
|---|---|---|
| User experience | URL stays the same in browser | Browser is redirected |
| Signal to search engines | Hint | Strong directive |
| Use case | Multiple valid URLs serving same content | Old URL has moved |
| Implementation | HTML tag | Server-side redirect |
When content has truly moved, a 301 redirect is preferable. When the same content needs to remain accessible at multiple URLs, a canonical tag is appropriate.
Common canonicalization scenarios
| Scenario | Recommended approach |
|---|---|
| HTTP vs HTTPS | 301 redirect HTTP to HTTPS; canonical tags reference HTTPS |
www vs non-www | 301 redirect to the chosen version; canonical tags reflect that |
| Trailing slash inconsistency | Pick one and 301 the other; canonical tags reflect choice |
| URL parameters (tracking, sorting, filtering) | Canonical to the parameter-free version |
| Mobile vs desktop URLs | Canonical from mobile URL to desktop URL (now rare with responsive design) |
| Pagination (page 1, 2, 3) | Each page canonical to itself; do not canonical all pages to page 1 |
| Duplicate product pages (same product in multiple categories) | Choose primary URL and canonical others to it |
Common implementation mistakes
- Canonical to
noindexd page. Conflicting signals confuse search engines - Canonical chains. Page A canonicals to B, which canonicals to C; canonical should point directly to the final destination
- Self-canonical with parameters. A URL
?ref=emailself-canonicalizing to itself includes the parameter; canonical should typically point to the parameter-free URL - Cross-domain canonical without permission. Should only be used when you have legitimate authority over both domains
- Canonical tag on every page identical. Pointing every page on a site to the homepage tells Google to index only the homepage
- Canonical inside the body rather than head. Search engines may not respect canonical tags placed outside the
<head>
Where canonical tags are added
| Platform | How canonicals are added |
|---|---|
| WordPress | Automatic by core or SEO plugins (Yoast, Rank Math) |
| Shopify | Automatic with built-in SEO settings |
| Squarespace, Wix, Webflow | Automatic in templates |
| Static sites / SSGs | Set in template or layout file |
| Custom sites | Added in HTML head, often via templating logic |
Most modern platforms generate canonical tags automatically; manual editing is needed primarily for non-standard cases.
Common misconceptions
- “Canonical tags guarantee which URL appears in search.” They are a hint; Google can choose a different canonical based on other signals.
- “You only need canonicals for duplicate content.” Self-referencing canonicals are good practice on every page.
- “Canonical tags pass full ranking signals.” They consolidate signals from duplicate pages but are weaker than 301 redirects for moved content.
- “
noindexand canonical do the same thing.”noindexremoves a page from search results; canonical consolidates signals to a different URL.