-2

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?

closed as unclear what you're asking by Scott Pack, Ward, Bryan, mdpc, Tom O'Connor Jul 1 '13 at 0:26

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

4

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.

  • Thanks. Please answer my other questions too: Search engines consider CNAME as alias so why not browser? Before setting 301 redirect, do I've to change the record of www to something other than CNAME? Like 'A'? Or it doesn't matter? – gom Jun 29 '13 at 17:51
  • How you configured your DNS is not relevant to this issue. – Michael Hampton Jun 29 '13 at 18:11
0

The CNAME doesn't mean that they will redirect, and doesn't cause the browser to rewrite the URL. Actually, browsers can display pretty much whatever they want in the URL bar, but in practice most will always rewrite it for HTTP redirects and never rewrite it for CNAME records.

CNAME indicates that the DNS data for a domain (and not its subdomains) is the same as that for another domain, but isn't a redirect per se.

Not the answer you're looking for? Browse other questions tagged or ask your own question.