Herself’s Webtools

Webtools for Webmasters: Scripts, HowTos, Templates, Plugins, Widgets, Tips and Useful Information

Herself’s Webtools header image 1

To www or not to www?

January 14th, 2008 · No Comments

Way back when all sites started with www. or something of that flavor.  That’s what told you whether you were on the web server, ftp server etc for that domain.  Now most sites have dropped the www and just use the domain name. Which should you do?

I think for new sites I’d follow the trend and not use www. Older sites are a bit more of problem. Not only do search engines frequently list www.yoursite.com and yoursite.com as two different sites but www.yoursite.com/page1.html and yoursite.com/page1.html will be ranked separately as well. Further, incoming links will point to one site or the other diluting your incoming link count.

The best thing to do is to pick one, www or no www. Then force all internal and external links to do the same. If you are using Wordpress there is a plugin to help you do that. If you are not using WP or would rather not use the plugin you can enforce www or not preferences in your .htaccess file:

Prefer www.yoursite.com
RewriteCond %{HTTP_HOST} !^www\.yoursite\.com [NC]
RewriteRule ^(.*)$ http://www.domain.com/$1 [L,R=301]

Prefer yoursite.com ( no www )
RewriteCond %{HTTP_HOST} ^www\.yoursite\.com$ [NC]
RewriteRule ^(.*)$ http://yoursite.com/$1 [L,R=301]

Google Webmaster tools also has an option for enforcing www vs not www preferences in its databases. See also ( Are you using Google Webmaster Tools )

Webmaster World has an Excellent discussion on whether or not to www also.

And do not forget to check that http://www.yourdomain.com and http://yourdomain.com both get you to your home page and not a ‘website not found’ page.

Tags: things you should know

0 responses so far ↓

  • There are no comments yet...Kick things off by filling out the form below.

You must log in to post a comment.