Canonical URL
A canonical URL is the preferred web address you want search engines to treat as the main version when similar content exists at multiple URLs.
Key facts
- Google defines canonicalization as selecting the representative URL for a piece of content.
- A canonical URL is the best representative page from a group of duplicate or near-duplicate pages.
- The rel="canonical" link element is the standard HTML signal to declare a preferred version.
- Google can choose a different canonical than the declared one if its signals indicate another URL is more representative.
- Canonicalization consolidates ranking signals like links toward the preferred URL.
Also called
rel=canonical, canonical link element, preferred URL
Use it for
Declaring the preferred URL among duplicates.
Applies to
All major search engines
How Canonical URLs Work
You declare a canonical URL by adding a <link> tag in the <head> of your page. The tag uses rel="canonical" and an href pointing to the preferred URL. Always use an absolute URL in the href value.
This signal tells search engines which version you consider the main one. It helps consolidate ranking signals and avoids duplicate content issues. For more detail on the tag itself, see how canonical tag works.
The canonical URL is a strong hint, not a command. Search engines may still choose a different URL if they find stronger signals. This is especially relevant when dealing with Duplicate Content across your site.
When to Use a Canonical URL
Use a canonical URL whenever the same or very similar content lives at multiple URLs. Common scenarios include:
URL parameters for tracking or sorting, www vs non-www versions, HTTP vs HTTPS, faceted navigation filters, and printer-friendly pages. Also use it for syndicated content on other domains.
For example, if your site has both http://example.com and https://example.com, set the canonical to the HTTPS version. Similarly, handle trailing slash variants with a canonical. Learn more about trailing slash seo in that context.
When building seo friendly url structures, ensure your canonical matches the cleanest version. Also consider URL Keywords when choosing which URL to canonicalize. Overall url optimization benefits from consistent canonicalization.
- Duplicate content from URL parameters (e.g., ?ref=abc, ?sort=price)
- www vs non-www and HTTP vs HTTPS variants
- Faceted navigation and filter pages
- Printer-friendly or AMP versions of the same page
- Syndicated content on other domains
Common Canonicalization Mistakes
Even experienced SEOs make errors with canonical URLs. Here are three frequent mistakes and their consequences.
First, using a canonical as a substitute for a redirect. If a page should not be accessible, use a 301 redirect instead. A canonical keeps the duplicate page indexable, which can cause confusion.
Second, pointing canonicals inconsistently across a chain of pages. Always point directly to the final preferred URL, not through intermediate pages. This avoids diluting signals.
Third, canonicalizing pages that are not truly duplicates. This can confuse search engines and may lead to the wrong page being indexed. For more on diagnosing these issues, see Canonical Error.
- Using canonicals instead of redirects for pages that should not exist
- Creating a chain of canonicals instead of pointing directly to the final URL
- Canonicalizing non-duplicate pages, confusing search engines
How Google Chooses the Canonical
Google considers multiple signals when selecting the canonical URL. Your declared canonical is one signal, but not the only one.
Other signals include internal links pointing to a specific URL, the URL listed in your sitemap, redirects, and the actual content similarity between pages. Google may also consider user signals and external links.
If Google finds stronger evidence that another URL is more representative, it may override your declared canonical. This is normal and does not necessarily indicate a problem. To influence Google's choice, ensure consistency across all signals.
Cross-Domain Canonical URLs
Canonical URLs can point to a different domain. This is useful when you syndicate content to other sites and want the original to be the canonical version.
For example, if your article appears on a partner site, you can add a canonical tag on that partner's page pointing back to your original URL. This tells search engines that your version is the authoritative one.
Cross-domain canonicals require mutual agreement and proper implementation. They help consolidate link equity and avoid duplicate content penalties across domains.
Common mistakes
- Using canonicals as a substitute for redirects when the duplicate page should not remain accessible. The duplicate page stays indexable, potentially confusing search engines and diluting ranking signals.
- Pointing canonicals inconsistently across a chain of pages instead of directly to the final preferred URL. Signals are diluted through the chain, and Google may not follow the intended path.
- Canonicalizing pages that are not truly duplicates or near-duplicates. Search engines may be confused and index the wrong page, harming your rankings.
Questions
what is canonical url in seo
A canonical URL is the preferred version of a page you want search engines to index when duplicate content exists. It helps consolidate ranking signals and avoid confusion. You declare it using a rel="canonical" link tag in the page's head.
how to add canonical tag in html
Add a <link> element in the <head> of your page with rel="canonical" and href pointing to the absolute URL of the preferred version. For example: <link rel="canonical" href="https://example.com/page/" />. Place it before any other link elements.
how to change canonical url in wordpress
In WordPress, use an SEO plugin like Yoast or Rank Math. In Yoast, open the post or page editor, scroll to the Yoast SEO meta box, click 'Advanced', and set the canonical URL. Alternatively, you can add a filter in your theme's functions.php file.
See also
- CanonicalCanonical SEO is the practice of telling search engines which URL should be treated as the pref…
- Shopify UrlsShopify URLs are the web addresses for a Shopify store and its pages, including the domain and …
- 301 SEOA 301 redirect is a permanent HTTP status code that tells browsers and search engines a page ha…
- Hreflang TagHreflang tags are HTML attributes that tell search engines which language or regional version o…
Sources
- Google Search Central developers.google.com
- Google Search Console Help support.google.com
- Conductor Academy conductor.com
- Moz Learn SEO moz.com
Outbound links are unpaid and nofollow. If one has gone stale, tell me.