Browser considering www domain and without www domain different

gom asked:

I’ve bought a domain name and hosted it. My browser is storing separate passwords for mydomain.com and www.mydomain.com, and also caching them separately. I want these two to be considered the same website.

The zone records of mydomain.com are:
“A” record: “@” points to the IP address of my hosting
CNAME: www points to “@”

As CNAME signifies alias, shouldn’t browser understand (like search engines do) that the two URLs refer to the same website? Is it browser’s fault?

Please tell how to correct the problem? Do I need to enter some other record for www instead of CNAME?

My answer:


The problem is that they are different.

If you really mean to have them be treated the same, you should permanently redirect one to the other using a 301 redirect.


View the full question and answer on Server Fault.

Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.