What is canonical and why should I use it – Figment Design

What is canonical and why should I use it

canonical htmlHinting to Search Engines the Preferred Version of a Document.

When you run a data driven site or have other reasons why a document might be duplicated it’s important to tell search engines which copy is the master copy, or in the jargon, the “canonical” copy. When a search engine indexes your pages it can tell when content has been duplicated. Without additional information, the search engine will decide which page best meets the needs of their customers. This might be fine, but there are many instances of search engines delivering old and outdated pages because they chose the wrong document as canonical.

It is very easy to tell search engines the canonical URL with meta data in the HEAD of your documents. Put the following HTML near the top of your HEAD element on every page that is not canonical:

<link rel="canonical" href="URL of the canonical page">

If you have access to the HTTP headers (such as with .htaccess or PHP) you can also set the canonical URL on files that don’t have an HTML HEAD, like a PDF. To do this, set the headers for non-canonical pages like this:

Link: <URL of the canonical page>; rel="canonical"

Read The Full Article Here