Forum Moderators: mack
And I am still confused on this so I am posting my query here...
My question is which is better http://www.example.com or http://example.com?
I would like to know the differenc between using http://www.example.com and http://www.example.com/?
If http://www.example.com is better why it is better any valid reasons? Major advantage of following this while doing SEO..
What are the problems we might face when we mix up using both in our site.?
This may seem bit messed up but please take some pain and clear my confusion.. Anybody please advice in detail...
Thanks a lot
Using .htaccess will ensure that SE's only spider one - this will enhance the page weight of those pages instead of spreading the wealth across both - which can cause problems.
Personally I use the former - natural linkage that is hand typed tends to include the www.
Similarly, most subdomains use subdomain.domain.com, not www.subdomain.doman.com - but the choice is yours.
What matters is YOUR site; if you have been using both, then in most cases, go with the flow - use the one that features best in the search engines.
If you use the Google Toolbar, read the page rank bar for each version, and go with the one that shows more green.
This is not an infallible test, but it is one of three fairly reliable uses for the little green bar. Note: if you have had any serious listing problems in Google recently, the test will not be reliable.
Most sites use www.domain.com, but that doesn't make it better or worse than domain.com - just different.Similarly, most subdomains use subdomain.domain.com, not www.subdomain.doman.com - but the choice is yours.
www.example.com is technically a subdomain of example.com although most A name records are set up so that they resolve to the same place although they need not.
however: sub.example.com and www.sub.example.com are actually two different subdomains.
www.example.com is technically a subdomain of example.com
....and historically was like that because "www" would be the "world wide web" server (usually a dedicated machine) on the network: example.com
Hence you still also see ftp.example.com or news.example.com - the subdomains were referring to particular servers on the network. Different machines.
These days many tasks tend to be performed by a single machine and/or routing tends to be done as much by port as by IP address. So in reality you could just forget the subdomains and use "example.com" for everything - FTP will automatically happen on port 21/22, web will automatically happen on port 80. Same machine, just a different port.
So there is no need for a subdomain to exist in order to tell the router where to send the request.
That's the reason why both means of addressing, with and without the "www", exist today.
There is absolutely no difference between them in SEO terms. It's really a personal matter of either what you prefer or what your users tend to use (or - good point made by Limbo - what most people tend to type when they link to you).
What you should do, as mentioned by others above, when you've decided which one you want, is to 301 redirect the other to the main one you've chosen.
TJ
Keep sharing ..
ok guys I have some confusion here as you all say its a matter of personal choice but here i am not able to make one maybe due to lack of experience or maybe knowledge..So how many of you would stick to www an d how many with non-www urls... I want to know which is more preferred by memebers here..
Please share with me
Thank you all
ok guys I have one more confusion here that about redirection .. i want know when we redirect from www to non www or vice versa will the PR and all back links get redirected?
will it make any difference if both of domains www and non www are indexed and showing up in google.. How they affect our rankings, pr etc..
please advice..
Thank you
will the PR and all back links get redirected?will it make any difference if both of domains www and non www are indexed and showing up in google.. How they affect our rankings, pr etc..
If you're trying to prepare for a potential disaster, then just assume the worst - you might lose rankings for a bit.
If it gives you peace of mind I recently went through this exercise with 4 sites and 301'd the non-www's to the www's. Both sets of URL's were in the index, each had it's own inbound links.
Nothing whatsoever went wrong. Long term, when the inbound links are all concentrated to the one URL set, rankings, if anything, will improve.
The truth is the engines should cater for this well. As long as there is nothing else that's "odd" about your site and pages, the engines should handle it without any trouble.
Dean
As for affecting page rank, if some people link to you with the WWW and some without, in theory that will split your page rank. The traditional solution is to just set up your htaccess file to either always force the WWW or always remove it.
How does the use of both in the site affect page rank?Google tends to see them as twio different sites, so your page rank is shared between them; the lions share going to the most commonly linked-to; the remains to the other (assuming it has some incoming links.
Plus the very large risk of supplementary listing due to the duplication.
Merging, via a 301, consolidates your rank (and ranking) in one place.
[edited by: mack at 10:31 am (utc) on Aug. 6, 2006]
[edit reason]
[1][edit reason] Fixed quote [/edit] [/edit][/1]
It would appear that folks running sites on Windows (IIS) servers are just out of luck when it comes to redirects, no?
While page redirects are possible, a non-www to www: (http://mysite.com - to - [mysite.com)...] doesn't seem possible unless it's done through IIS.
Most hosts probably don't have the "non-www" domain name redirecting to the "www" one.
---------------------
Domain Level 301 Redirect in IIS
"non-www" to "with-www"
1. After the www.example.com website is set up, now set up
example.com (without the www) in Internet Services Manager.
2. Select the example.com web site in Internet Services
manager and enter the properties.
3. In the Home Directory tab, change the option button "When
connecting to this resource the content should come from" to
"A redirection to a URL".
4. Specify the URL as http://www.example.com
5. Check the checkbox that says "A permanent redirection for
this resource."
------------------------
Save the following code it in a file named redirect.asp and then add to the top of each file on your site the following snippet: <!-- #Include file="redirect.asp" -->
<%@ Language=VBScript %>
<%
Domain_Name = lcase(request.ServerVariables("HTTP_HOST"))
if domain_name <> "www.example.com" Then
HTTP_PATH = request.ServerVariables("PATH_INFO")
QUERY_STRING = request.ServerVariables("QUERY_STRING")
theURL = "http://www.example.com" & HTTP_PATH
if len(QUERY_STRING) > 0 Then
theURL = theURL & "?" & QUERY_STRING
end if
Response.Clear
Response.Status = "301 Moved Permanently"
Response.AddHeader "Location", theURL
Response.Flush
Response.End
end if
%>
Be sure to replace example.com with your own domain name and in lower case only. I haven't personally tested this code on a site, but others report that it works great.
If you use this code, I suggest you save it in a file named redirect.asp and then add to the top of each file on your site the following snippet:
<!-- #Include file="redirect.asp" -->
If you have files in sub-directories, then add the appropriate path info or use a fully qualified path.
A fuller discussion on this approach and variations can be found here:
[webmasterworld.com...]
I feel it was quite important information that we shared here. That will really be helful for newbie like me..
Btw way trillian I can understand the pain you might have went through..
Tedster thanks for sharing... I had an idea of redirecting in php but not in asp..Your post was quite helpful..
Now I would like to know few more things regarding the redirect procedure...Like
is it ok to use redirect on old website which is already having a good PR and its has thousands of pages indexed in Google? If not what should we do? If yes how should we do that?
Can anyone provide me with the detail code and process of redirecting..and explain how its done in php and in asp.
For e.g there is one site whose page names are changed now I need to know the each and every process to redirect the old pages to new ones.. Also if anything else that would be helpful for me..
Anyone please help on this..
Excuse me if my question is not clear..
And frens do keeep posting
Thanks once again
I consider WWW to be just really, really lame, since it's so unnecessary
Given the other replies in the thread it just goes to show that this is a 100% personal preference issue. Some prefer with, some prefer without.
php
You might want to now start a new thread in the PHP forum specifically relating to the redirect issue.
TJ
The general population seems to assume that "www" must be there.
As other mentioned the www. could be a hinderance from a branding perspective and makes for longer URLs that are more likely to be broken across multiple lines in email messages.
I personally have set my server's to 301 redirect to the non-www version of my domains.