I’ve been keeping an eye on a very interesting discussion about the difference between the Google pagerank of pages on a “www” domain name and the same page without the “www” prefix (e.g. “www.intuitive.com/index.html” versus “intuitive.com/index.html”). Google calculates pagerank based on quite a few different criteria – as detailed in my article How does Google figure out what pages are more relevant? Pagerank. – and if you care about that, and you should, you should be automatically mapping all non-www URLs to their www equivalent.
And here’s how to do just that…
In your httpd.conf file, look for an entry like this:
<VirtualHost bestbookbuys.com> ServerAlias www.bestbookbuys.com
That’s the problem in a nutshell: you are defining the “real” name of the Web site to be the domain name without the www prefix. To fix it, change the above entry to something more like:
without any ServerAlias entry at all.
Failing that, if you have an entry in your httpd.conf that’s more like this:
<VirtualHost www.auctionincome.com> ServerAlias auctionincome.com
just remove the ServerAlias line.
Either way, you’ll also want to, later in the httpd.conf file, add this:
<VirtualHost auctionincome.com> Redirect permanent / http://www.auctionincome.com/ </VirtualHost>
This is explained in some detail in
the Apache documentation too, if you want more detail.
One cool additional feature: a Redirect of this nature copies everything after the first slash, so a URL like
auctionincome.com/abc/def.html will redirect to
www.auctionincome.com/abc/def.html, which is exactly what you want.