Why do some urls require www




















Then your web server will have the URL www. So all in all , it is all in the name. Because of the embeded beauty of the name www, many use it. Your university has included www for registration of its domain name with their Internet Service provider. That is why you are unable to get the site otherwise.

I hope I am a layman. Sign up to join this community. The best answers are voted up and rise to the top. Stack Overflow for Teams — Collaborate and share knowledge with a private group.

Create a free Team What is Teams? Learn more. Why can't some websites be shown without the "www" in the URL? Asked 12 years, 4 months ago.

Active 7 years, 7 months ago. Viewed 47k times. Improve this question. Why the close votes? Maybe this person really doesn't know. Not really programming-related, but could be of use to web developers — activa. Seems more of an end-user question than a serverfault "sysadmin" question. Belongs elsewhere? For someone new in server admin who doesn't know how DNS works I think this is a completely valid question.

Its asking how DNS works. Show 1 more comment. Active Oldest Votes. Improve this answer. Add a comment. John Saunders. It's not sufficient to set up two domain names in DNS. This way, search engines don't index the same page several times, potentially leading to it being considered as duplicate content or spam, and even removing or lowering your page from the search engine result pages.

When adding such a tag, you serve the same content for both domains, telling search engines which URL is canonical. Unlike the previous case, browser history will consider non-www and www URLs as independent entries. With these techniques, you can configure your server to respond correctly for both, the www-prefixed and the non-www-prefixed domains.

It is a matter of choosing which type you want to use as your canonical location, then redirecting the other type to it. This is a very subjective topic it could be considered a bikeshedding issue.

If you wish to read deeper, please see some of the many articles on the subject. Yes , you need to choose one and stick with it. The choice of which one to have as your canonical location is yours, but if you choose one, stick with it.

However, these benefits only apply in case of large websites that have multiple subdomains and many servers. In case of a small website, it does not matter which type of domain you use, and even a non-www one works just the same as a www one. The counter-argument is that everyone wants their website to grow, and should prepare for that, instead of thinking small.

So, even if you have a small website now, you should prepare for it to grow later. This is, again, a personal or brand choice. Those slight advantages give www domains a small edge. It's more of an indirect, positive effect. However, this effect is not very significant, and you can do away with it and use a non-www domain. Website performance and a better user experience will weigh even more heavily, so as long as you don't lose performance, you can make the choice for either one.

Also, the benefits that www domains do offer can be replicated for non-www domains with some workarounds. For example, you can use a separate domain altogether to host your static content. This will make the cookie restriction functionality of a www domain unnecessary. So, if you have a non-www domain, you can still find workarounds to get the same benefits as those of a www domain.

If you have a large website or anticipate your website to grow, you should opt for a www domain. It does not add that much complexity to the name and has some inherent technical advantages. If you have a small website, using a www domain is unnecessary. So, it is your personal choice whether you want to go for a www or a non-www domain. It would make practically no difference whatsoever, no matter which one you choose.

The short answer to the www vs non-www question is that there is no major difference, but there are small benefits. These are especially beneficial for large websites with multiple subdomains and servers. From an SEO perspective, the differences are incredibly marginal, with www domains having some advantages.



0コメント

  • 1000 / 1000