Hello Robot: Tobias Gärder om design, webbutveckling och mjukvara.

Handling Canonical URL’s With Wordpress

Up until now a constant SEO issue has been dealing with duplicate content, pages that can be reached through different url’s and therefore regarded as dupes, like the following:

http://www.mydomain.com/mypage.html

http://www.mydomain.com/mypage.html?category=misc


http://www.mydomain.com/mypage.html?sessionid=1234

These three url’s all point to the same page but would be looked at as three different pages with identical content by the search engines. To help us deal with this Google, Yahoo! and Microsoft now supports the link rel=”canonical” tag.

Just put it in your <head>-section along with the url you prefer to inform them which address they should use instead of eventual dupes.

<link rel="canonical" href="http://www.mydomain.com/mypage.html" />

The search engines considers this a strong hint, not a directive. This means that they’ll most probably use the information you provide but they reserve the right to ignore it if it looks like it’s misused. You can refer to an url that redirects but they don’t allow you to redirect to another domain, and you can define relative paths.

Joost de Walk has put together a simple install-and-forget Wordpress plugin to handle this automatically, available for download here. Just put it in your /wp-content/plugins/-path, activate it and you’re set.

Read more about it at Google Webmaster Central and Robert’s Talk.

  • atw
    This is a cool theme but where can I find the widgets for it?

    Thanks!
blog comments powered by Disqus