rel-canonical: Difference between revisions
Kevin Marks (talk | contribs) m (copypasta error) |
Kevin Marks (talk | contribs) (→Discussion: a ignore) |
||
Line 12: | Line 12: | ||
There are many reasons for a site to serve the same content at multiple URLs, but duplicate pages are undesirable in search results. The [https://www.mattcutts.com/blog/seo-advice-url-canonicalization/ historic recommendation] was to use 301 redirects to the canonical page, but that can be jarring for users. There are many use cases for a URL to have additional information added as query parameters or fragments to indicate the navigation history for referral purposes, but would prefer a single main referent from searches. This was codified in February 2009 as rel=canonical, and [https://webmasters.googleblog.com/2009/02/specify-your-canonical.html adopted] by [http://www.ysearchblog.com/2009/02/12/fighting-duplication-adding-more-arrows-to-your-quiver/ many] [https://blogs.msdn.microsoft.com/webmaster/archive/2009/02/12/partnering-to-help-solve-duplicate-content-issues.aspx search] [https://web-beta.archive.org/web/20091008070823/http://blog.ask.com/2009/02/ask-is-going-canonical.html engines]. | There are many reasons for a site to serve the same content at multiple URLs, but duplicate pages are undesirable in search results. The [https://www.mattcutts.com/blog/seo-advice-url-canonicalization/ historic recommendation] was to use 301 redirects to the canonical page, but that can be jarring for users. There are many use cases for a URL to have additional information added as query parameters or fragments to indicate the navigation history for referral purposes, but would prefer a single main referent from searches. This was codified in February 2009 as rel=canonical, and [https://webmasters.googleblog.com/2009/02/specify-your-canonical.html adopted] by [http://www.ysearchblog.com/2009/02/12/fighting-duplication-adding-more-arrows-to-your-quiver/ many] [https://blogs.msdn.microsoft.com/webmaster/archive/2009/02/12/partnering-to-help-solve-duplicate-content-issues.aspx search] [https://web-beta.archive.org/web/20091008070823/http://blog.ask.com/2009/02/ask-is-going-canonical.html engines]. | ||
Search engines prefer <code>rel=canonical</code> on a <code><link></code> element, and will ignore it on an <code><a></code> element. | Search engines prefer <code>rel=canonical</code> on a <code><link></code> element, and will [https://www.mattcutts.com/blog/rel-canonical-html-head/ ignore it] on an <code><a></code> element. | ||
== Issues == | == Issues == |
Revision as of 10:24, 28 March 2017
<entry-title>rel-canonical</entry-title> Kevin Marks (Editor)
rel=canonical is a link relation to indicate the canonical URL of the current page, to avoid duplicate content.
Per CC0, to the extent possible under law, the editors have waived all copyright and related or neighboring rights to this work. In addition, as of 2024-11-28, the editors have made this specification available under the Open Web Foundation Agreement Version 1.0.
Abstract
By adding rel="canonical"
to a hyperlink, a page indicates that the destination of that hyperlink SHOULD be considered the preferred or definitive version of the current page. This helps search engines avoid duplicate content, and is useful for deciding how to link to a page when citing it.
Discussion
There are many reasons for a site to serve the same content at multiple URLs, but duplicate pages are undesirable in search results. The historic recommendation was to use 301 redirects to the canonical page, but that can be jarring for users. There are many use cases for a URL to have additional information added as query parameters or fragments to indicate the navigation history for referral purposes, but would prefer a single main referent from searches. This was codified in February 2009 as rel=canonical, and adopted by many search engines.
Search engines prefer rel=canonical
on a <link>
element, and will ignore it on an <a>
element.