Redirect Users to www
I’ve always been annoyed by people accessing my sites without using www (i.e. requesting cellarspot.com instead of www.cellarspot.com). This is annoying because it can hurt SEO and it also confuses Google Analytics. I’ve found a fix!
Using Apache mod_rewrite you can create a rule as follows, either in httpd.conf or in a .htaccess file:
sh: /usr/bin/states: No such file or directory
3 Comments so far
Leave a reply

Good snag Al. You are a nerd. Oh wait, I wrote this from my phone while snowboarding.
Is there any reason you chose to add “www” rather than remove it?
I’m not sure why I like having the http://www. I’ll think about this, Sunil, and maybe make a post about how to remove the http://www. Speaking of which, the article I linked to has code that allows you to remove http://www.