Sometimes, you have an unavoidable situation where two or more pages are essentially duplicates of each other, and for some reason you can’t delete all the duplicate pages. Often, this happens when using dynamic URLs because your web server is generating similar URLs for the exact same content.
The best solution in this situation is to converge on a single URL by changing the URL generation or deleting duplicate pages, but sometimes this is difficult to do, especially within large websites. An alternative approach is to tell the search engine that you have duplicate content, but that the search engine should always use the same URL for all versions of the page–the canonical URL.
To use this technique, add the following URL pattern in the head portion of your duplicate page:
<link href=”http://www.example.com/address-of-authoritative-page” rel=”canonical” />
Ensure that you replace “example.com/address-of-authoritative-page” with the actual address. This tag informs your search engine that the page containing the tag is a duplicate, and that the search engine should include the listed URL in its index instead of the duplicate page. That way, the search engine always knows the best URL for the page to show to the searcher.