Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Possible Duplicate:
What’s the point in having “www” in a URL?

Why do we prepend our URLs with "www", isn't http:// enough? Its clearly not necessarily because it is omissible.

However there is a particular circumstance where the use of "www" breaks the URL, when there is a subdomain.

Almost everytime I tell a non technical person to go to a url like blog.stackoverflow.com they try to go to www.blog.stackoverflow.com because they think all URLs start with "www." and get confused when it doesn't work.

Is there a technical reason for the "www" or was it just invented for semantical reasons?

Is there anything being done to address this or is it considered a non issue?

share|improve this question

marked as duplicate by RobM, splattne Jul 1 '11 at 14:50

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

2  
This is definitely a non-issue, and I am frustrated by those that try to make it an issue. (I'm looking at you, WordPress.) How you configure your DNS records is your business, not someone else's. Yes, it is good to set the proper records so both non-www and www get you to your website, but remember that there are other services out there that end up on other common hostnames, as pointed out by Mark and Jakob. –  Brad Jul 1 '11 at 13:30
1  
2  
If you choose to use a bare domain, example.com, for serving web content, and set cookies on this domain instead of on www.example.com, then you've forced all sub-domains, e.g. blog.example.com, to be include these cookies. This becomes an issue if you want to serve static content from a separate server/sub-domain like static.example.com. In this case you would need to secure a second domain for hosting only static content. –  jscott Jul 1 '11 at 13:41
1  
@JdeBP please don't take it personally, when I say WE I mean like when I say "WE drive cars" you may not drive a car, you might ride a bike, and I may not be talking about YOU, but still a lot of people drive cars and a lot of people use www. –  JD Isaacks Jul 1 '11 at 14:16
1  
Whoever said anything about personal? Did you not get that all of those people coming to ServerFault that I pointed to (amongst others) are not me? I assert that it isn't even "a lot of people" who do what you describe in the question. Heck, WWW browsers have for a long time had a search path mechanism to try to cope with the many people who leave the "www" off. –  JdeBP Jul 1 '11 at 14:48

2 Answers 2

up vote 5 down vote accepted

The "best practice" for internet services was to use ALIASes named after roles. So you pointed people to "www.yourdomain.xyz" for web, "ftp.yourdomain.xyz", and so on even if you only had one giant computer running the entire place.

The gain was when you got a second, giant computer you could split up the roles and no one would have to change any links or configurations.

You just live in a world where 99.99% of the domains are used strictly for websites. Pointing the core domain name to a cruddy, "probably faddish and never going to amount to anything", webserver rather than a key DNS or directory authentication machine was SHEER MADNESS once upon a time. ;-)

Nothing is being done to address it except recommend that people alias www.you.blog.xyz to you.blog.xyz so that it doesn't cause issues for people who expect it. Heck, if you are using the domain for a single service on a single machine/cloud I recommend you alias *.you.domain.xyz so that ANYTHING works, even "thisshouldntwork.you.blog.xyz".

share|improve this answer
    
That makes sense, however, if you are using an SSL, won't this break it? Thanks. –  JD Isaacks Jul 1 '11 at 13:32
2  
@John, depends on your SSL certificate (single host header, multiple host header under that domain, or wildcard domain) –  Brandon Jul 1 '11 at 13:39
    
@routeNpingme thanks, I didn't know about those options. –  JD Isaacks Jul 1 '11 at 14:13

'www' is just one kind of service, of which there may be many running on any given domain. But the domain itself can only point to one* server.

Today it's a very common service, but at the time the standard (well, practice) was minted there was no real reason to assume HTTP would be used rather than, say, Gopher.

A better solution would have been for the web browser to look for SRV records from the start, but now it's kind of too late to change.

*) Yes, you can have several A records and so on, but they better be indistinguishable from a user point of view.

share|improve this answer
1  
It's not too late to change. The way that SRV records are specified to be used, after all, is to fall back to the old (i.e. current) service location behaviour in the absence of SRV resource records. The shameful truth is that in fact there is no reason for not bringing WWW browsers into the 21st century. All of the technical issues were solved years ago. –  JdeBP Jul 1 '11 at 14:00

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