Having domain.com and www.domain.com & SEO

classic Classic list List threaded Threaded
27 messages Options
12
Reply | Threaded
Open this post in threaded view
|

Having domain.com and www.domain.com & SEO

Marc Pinnell-3
=== Moved from Apache Lasso Directives Thread ===

Bil,

Funny you should mention this. I just ran across an article talking  
about this very thing over the holidays and was going to ask what the  
groups thoughts on this and the best way to handle it. Wow, two birds,  
one stone! There was also an example in that article that intrigued me:

<VirtualHost domain.com www.domain.com>
        ... path info and directives here
</VirtualHost>

Notice the VirtualHost line. Now I have always written out mine with  
the IP number:

<VirtualHost 12.345.56.78:80>

How does their example work and is it a better solution. Sure seems a  
lot less redundant.

Marc

On Jan 19, 2009, at 4:03 PM, Bil Corry wrote:

> (2) You allow both domain.com and www.domain.com to resolve to the  
> same path.  This will mess up your SEO as there is now duplicate  
> content at two URLs.  I'd suggest you force the user to one or the  
> other, and I'd actually recommend going with www.domain.com as the  
> URL to serve from:
>
>    # add "www"
>    RewriteCond %{HTTP_HOST} !^www\.domain\.com$
>    RewriteRule (.*)  <a href="http://www.domain.com%">http://www.domain.com%{REQUEST_URI} [L,NS,R=301]

--
Marc Pinnell
1027 Design
PO Box 990872
Redding, CA 96099-0872
530.941.4706
fax: 866.232.5300
www.1027Design.com



--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

Bil Corry-3
Marc Pinnell wrote on 1/19/2009 6:10 PM:
> <VirtualHost domain.com www.domain.com>
>     ... path info and directives here
> </VirtualHost>

Do *not* do this, it means Apache is at the mercy of DNS and your site will not be available if you have a DNS hiccup:

        http://httpd.apache.org/docs/2.0/dns-caveats.html


- Bil


--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

Marc Pinnell-3
Throwing that note away.... :-)


On Jan 19, 2009, at 4:21 PM, Bil Corry wrote:

> Marc Pinnell wrote on 1/19/2009 6:10 PM:
>> <VirtualHost domain.com www.domain.com>
>>    ... path info and directives here
>> </VirtualHost>
>
> Do *not* do this, it means Apache is at the mercy of DNS and your  
> site will not be available if you have a DNS hiccup:
>
> http://httpd.apache.org/docs/2.0/dns-caveats.html
>
>
> - Bil
>
>
> --
> This list is a free service of LassoSoft: http://www.LassoSoft.com/
> Search the list archives: http://www.ListSearch.com/Lasso/Browse/
> Manage your subscription: http://www.ListSearch.com/Lasso/
>

--
Marc Pinnell
1027 Design
PO Box 990872
Redding, CA 96099-0872
530.941.4706
fax: 866.232.5300
www.1027Design.com




--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

Marc Pinnell-3
In reply to this post by Marc Pinnell-3
Bil,

Should your RewriteRule below actually change what is displayed in the  
browser URL field? I implemented it, but nothing visible is changing.

marc


On Jan 19, 2009, at 4:10 PM, Marc Pinnell wrote:

> === Moved from Apache Lasso Directives Thread ===
>
> Bil,
>
> Funny you should mention this. I just ran across an article talking  
> about this very thing over the holidays and was going to ask what  
> the groups thoughts on this and the best way to handle it. Wow, two  
> birds, one stone! There was also an example in that article that  
> intrigued me:
>
> <VirtualHost domain.com www.domain.com>
> ... path info and directives here
> </VirtualHost>
>
> Notice the VirtualHost line. Now I have always written out mine with  
> the IP number:
>
> <VirtualHost 12.345.56.78:80>
>
> How does their example work and is it a better solution. Sure seems  
> a lot less redundant.
>
> Marc
>
> On Jan 19, 2009, at 4:03 PM, Bil Corry wrote:
>
>> (2) You allow both domain.com and www.domain.com to resolve to the  
>> same path.  This will mess up your SEO as there is now duplicate  
>> content at two URLs.  I'd suggest you force the user to one or the  
>> other, and I'd actually recommend going with www.domain.com as the  
>> URL to serve from:
>>
>>   # add "www"
>>   RewriteCond %{HTTP_HOST} !^www\.domain\.com$
>>   RewriteRule (.*)  <a href="http://www.domain.com%">http://www.domain.com%{REQUEST_URI} [L,NS,R=301]
>
> --
> Marc Pinnell
> 1027 Design
> PO Box 990872
> Redding, CA 96099-0872
> 530.941.4706
> fax: 866.232.5300
> www.1027Design.com
>
>

--
Marc Pinnell
1027 Design
PO Box 990872
Redding, CA 96099-0872
530.941.4706
fax: 866.232.5300
www.1027Design.com




--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

Bil Corry-3
Marc Pinnell wrote on 1/19/2009 7:23 PM:
> Should your RewriteRule below actually change what is displayed in the
> browser URL field? I implemented it, but nothing visible is changing.

Yes, the browser should redirect to the www.domain.com URL.  The way it's written, it should actually do it also if the case is anything but lower (e.g. www.Domain.com).

You have to restart Apache to see the change.


- Bil


--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

Marc Pinnell-3
I made the change to my conf file for my business affiliated domains  
and all of a sudden all URLs started displaying the same site (when  
they shouldn't). I must have done something wrong with the rewrite.

Here's a sample (call either domain or domain2 and get the domain site):
<VirtualHost 12.345.56.78:80>
        ServerName domain.com
        DocumentRoot /path/to/site/domain
        # add "www"
                RewriteCond %{HTTP_HOST} !^www\.domain\.com$
                RewriteRule (.*)  <a href="http://www.domain.com%">http://www.domain.com%{REQUEST_URI} [L,NS,R=301]
</VirtualHost>
       

<VirtualHost 12.345.56.78:80>
        ServerName domain2.com
        DocumentRoot /path/to/site/domain2
        # add "www"
                RewriteCond %{HTTP_HOST} !^www\.domain2\.com$
                RewriteRule (.*)  <a href="http://www.domain2.com%">http://www.domain2.com%{REQUEST_URI} [L,NS,R=301]
</VirtualHost>

Marc


On Jan 19, 2009, at 5:42 PM, Bil Corry wrote:

> Marc Pinnell wrote on 1/19/2009 7:23 PM:
>> Should your RewriteRule below actually change what is displayed in  
>> the
>> browser URL field? I implemented it, but nothing visible is changing.
>
> Yes, the browser should redirect to the www.domain.com URL.  The way  
> it's written, it should actually do it also if the case is anything  
> but lower (e.g. www.Domain.com).
>
> You have to restart Apache to see the change.
>
>
> - Bil
>
>
> --
> This list is a free service of LassoSoft: http://www.LassoSoft.com/
> Search the list archives: http://www.ListSearch.com/Lasso/Browse/
> Manage your subscription: http://www.ListSearch.com/Lasso/
>

--
Marc Pinnell
1027 Design
PO Box 990872
Redding, CA 96099-0872
530.941.4706
fax: 866.232.5300
www.1027Design.com




--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

Marc Pinnell-3
In reply to this post by Bil Corry-3
Found it. Time to pack it in for the evening....

Amazing how much better it works when you put in:

RewriteEngine On

:-(

Marc


On Jan 19, 2009, at 5:42 PM, Bil Corry wrote:

> Marc Pinnell wrote on 1/19/2009 7:23 PM:
>> Should your RewriteRule below actually change what is displayed in  
>> the
>> browser URL field? I implemented it, but nothing visible is changing.
>
> Yes, the browser should redirect to the www.domain.com URL.  The way  
> it's written, it should actually do it also if the case is anything  
> but lower (e.g. www.Domain.com).
>
> You have to restart Apache to see the change.
>
>
> - Bil
>
>
> --
> This list is a free service of LassoSoft: http://www.LassoSoft.com/
> Search the list archives: http://www.ListSearch.com/Lasso/Browse/
> Manage your subscription: http://www.ListSearch.com/Lasso/
>

--
Marc Pinnell
1027 Design
PO Box 990872
Redding, CA 96099-0872
530.941.4706
fax: 866.232.5300
www.1027Design.com




--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

Marc Pinnell-3
In reply to this post by Bil Corry-3
Oh and thanks  for the help and patience!

Marc


On Jan 19, 2009, at 5:42 PM, Bil Corry wrote:

> Marc Pinnell wrote on 1/19/2009 7:23 PM:
>> Should your RewriteRule below actually change what is displayed in  
>> the
>> browser URL field? I implemented it, but nothing visible is changing.
>
> Yes, the browser should redirect to the www.domain.com URL.  The way  
> it's written, it should actually do it also if the case is anything  
> but lower (e.g. www.Domain.com).
>
> You have to restart Apache to see the change.
>
>
> - Bil
>
>
> --
> This list is a free service of LassoSoft: http://www.LassoSoft.com/
> Search the list archives: http://www.ListSearch.com/Lasso/Browse/
> Manage your subscription: http://www.ListSearch.com/Lasso/
>

--
Marc Pinnell
1027 Design
PO Box 990872
Redding, CA 96099-0872
530.941.4706
fax: 866.232.5300
www.1027Design.com




--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

Jolle Carlestam-2
In reply to this post by Marc Pinnell-3
20 jan 2009 kl. 01.10 skrev Marc Pinnell:

> === Moved from Apache Lasso Directives Thread ===
> Funny you should mention this. I just ran across an article talking
> about this very thing over the holidays and was going to ask what the
> groups thoughts on this and the best way to handle it.

> On Jan 19, 2009, at 4:03 PM, Bil Corry wrote:
>
>> (2) You allow both domain.com and www.domain.com to resolve to the
>> same path.  This will mess up your SEO as there is now duplicate
>> content at two URLs.  I'd suggest you force the user to one or the
>> other, and I'd actually recommend going with www.domain.com as the
>> URL to serve from:

Probably cause I don't want to mess with my principles. But I prefer  
the other way around.
I want to evolve into a world where we don't use www.xyz.tld at all.  
It's such a waste of space. xyz.tld is all that's needed.

Everyone recognizes name.com, name.se, name.sj as urls. No need to put  
www in front of them for pedagogical reasons.
And yet a LOT of users still adds them to the url even if you've  
written them without. Because they think it's mandatory.

I want to teach them that www is not necessary by redirecting them to  
a site without it.

Bil's argument for his reverse viewpoint is that you could get better  
search engine ranking using a www url. But that's only true as long as  
www urls are common.
So I want to be member of a movement that eradicates www from the face  
of the earth. Or at least our urls.

Users of Internet, Unite! No More WWW!

And now over to other important matters...

HDB
Jolle

--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

Johan Solve
On Tue, Jan 20, 2009 at 9:30 AM, Jolle Carlestam <[hidden email]> wrote:
> Probably cause I don't want to mess with my principles. But I prefer the
> other way around.
> I want to evolve into a world where we don't use www.xyz.tld at all. It's
> such a waste of space. xyz.tld is all that's needed.
>
> Everyone recognizes name.com, name.se, name.sj as urls. No need to put www
> in front of them for pedagogical reasons.
> And yet a LOT of users still adds them to the url even if you've written
> them without. Because they think it's mandatory.

I used to think this as well but I've changed my mind and now prefer
to redirect to the www variant.

The main reason is to keep the actual web site clearly separated from
other sub domains or host names under the domain such as
blog.domain.com, beta.domain.com etc. The www prefix states that "this
is our main public web site", and otherwise you will get also all
those other things on a site:domain.com search.

But the absolutely most important thing which we all agree on is to
make sure to support URLs without www as well, and redirect them to
the preferred variant. My steam pressure builds up every time I come
across a major site that doesn't support no-www addressing.

--
Mvh
Johan Sölve
____________________________________
Montania System AB
Halmstad   Stockholm   Malmö
http://www.montania.se

Johan Sölve
Mobil +46 709-51 55 70
[hidden email]

Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
Telefon +46 35-136800 |  Fax +46 35-136801

--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

Johan Solve
In reply to this post by Marc Pinnell-3
On Tue, Jan 20, 2009 at 11:05 AM, Johan Solve <[hidden email]> wrote:
> The main reason is to keep the actual web site clearly separated from
> other sub domains or host names under the domain such as
> blog.domain.com, beta.domain.com etc. The www prefix states that "this
> is our main public web site", and otherwise you will get also all
> those other things on a site:domain.com search.

Also, I've given up on the "educate the users" battle that I've
realized I can't win... As you say a lot of "normal" users add www
before urls just out of old habit, or thinking that there must be www
or otherwise it won't work. Even certain people in my own family keep
adding www in front of every web address...


--
Mvh
Johan Sölve
____________________________________
Montania System AB
Halmstad   Stockholm   Malmö
http://www.montania.se

Johan Sölve
Mobil +46 709-51 55 70
[hidden email]

Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
Telefon +46 35-136800 |  Fax +46 35-136801

--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

Jolle Carlestam-2
In reply to this post by Johan Solve
20 jan 2009 kl. 11.05 skrev Johan Solve:

> My steam pressure builds up every time I come
> across a major site that doesn't support no-www addressing

Agree!
It's amazing how often this happens even for major, high volume sites!

HDB
Jolle

--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

Jolle Carlestam-2
In reply to this post by Johan Solve
20 jan 2009 kl. 11.09 skrev Johan Solve:

> Even certain people in my own family keep adding www in front of  
> every web address...

Know what you mean. Got them in my family too. We're not using the  
educational whip firmly enough...

Internet users of the World! Unite! Spank those that put www first!
I will never surrender even if I'll stand on the barricades alone!

HDB
Jolle

--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

Jonathan Vanherpe (T & T NV)
Jolle Carlestam wrote:

> 20 jan 2009 kl. 11.09 skrev Johan Solve:
>
>> Even certain people in my own family keep adding www in front of every
>> web address...
>
> Know what you mean. Got them in my family too. We're not using the
> educational whip firmly enough...
>
> Internet users of the World! Unite! Spank those that put www first!
> I will never surrender even if I'll stand on the barricades alone!
>
> HDB
> Jolle
>
I wouldn't bother trying to educate users on something like that,
there's more important things they need to be educated about (there is
no Nigerian prince needing your help, don't download software from the
internet, and if you get an error/warning READ what it says). I really
don't mind if they type the whole url even if they could just limit
themselves to typing a few chars and have the suggestion bar take care
of the rest.

Jonathan

--
Jonathan Vanherpe - Tallieu & Tallieu NV - [hidden email]

--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

Johan Solve
In reply to this post by Jolle Carlestam-2
On Tue, Jan 20, 2009 at 11:18 AM, Jolle Carlestam <[hidden email]> wrote:

> 20 jan 2009 kl. 11.09 skrev Johan Solve:
>
>> Even certain people in my own family keep adding www in front of every web
>> address...
>
> Know what you mean. Got them in my family too. We're not using the
> educational whip firmly enough...
>
> Internet users of the World! Unite! Spank those that put www first!
> I will never surrender even if I'll stand on the barricades alone!

Or, if you can't beat them, join them.


--
Mvh
Johan Sölve
____________________________________
Montania System AB
Halmstad   Stockholm   Malmö
http://www.montania.se

Johan Sölve
Mobil +46 709-51 55 70
[hidden email]

Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
Telefon +46 35-136800 |  Fax +46 35-136801

--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

Jolle Carlestam-2
In reply to this post by Jonathan Vanherpe (T & T NV)
20 jan 2009 kl. 11.26 skrev Jonathan Vanherpe (T & T NV):

> there is no Nigerian prince needing your help,

What!
Now you tell me?!

Part from the joke, I agree.
But I'm not strong enough for the big fights. I'll stand on my small,  
safe barricade and you can master those important ones with real  
villains as opposition.

HDB
Jolle

--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

Bil Corry-3
In reply to this post by Jolle Carlestam-2
Jolle Carlestam wrote on 1/20/2009 2:30 AM:
> Bil's argument for his reverse viewpoint is that you could get better
> search engine ranking using a www url. But that's only true as long
> as www urls are common.

Actually, my argument is that you should pick one and redirect from the other for SEO -- two URLs to the same content is a no-no.

I was *suggesting* that you redirect from domain.tld to www.domain.tld, that is, use the www.domain.tld as the "official" URL.  The big reason is security -- say you use domain.tld as your "official" URL, then if you add a blog (blog.domain.tld) and it has a XSS hole, it can then read the cookie from the main site:

        http://taossa.com/index.php/2007/02/08/same-origin-policy/#parent_domain

At least by compartmentalizing each domain, you avoid this problem.


- Bil


--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

CoMedia
In reply to this post by Marc Pinnell-3
Marc Pinnell-3 wrote
Throwing that note away.... :-)
Google advises to use 301 redirects for this purpose

http://www.google.com/support/webmasters/bin/answer.py?answer=93633

-- Alfred
Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

Johan Solve
In reply to this post by Marc Pinnell-3
On Wed, Jan 21, 2009 at 1:12 AM, CoMedia <[hidden email]> wrote:
> Google advises to use 301 redirects for this purpose
>
> http://www.google.com/support/webmasters/bin/answer.py?answer=93633

And to put this in a lasso context, [redirect_url] defaults to a 302
redirect which will not be followed by search engines since it is
considered a temporary move.
Use [redirect_url: 'http://domain.com/new_url', -type=301] for a
permanent redirect that will be followed by search engines.

--
Mvh
Johan Sölve
____________________________________
Montania System AB
Halmstad   Stockholm   Malmö
http://www.montania.se

Johan Sölve
Mobil +46 709-51 55 70
[hidden email]

Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
Telefon +46 35-136800 |  Fax +46 35-136801

--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

Reply | Threaded
Open this post in threaded view
|

Re: Having domain.com and www.domain.com & SEO

Bil Corry-3
Johan Solve wrote on 1/21/2009 4:08 AM:

> On Wed, Jan 21, 2009 at 1:12 AM, CoMedia <[hidden email]> wrote:
>> Google advises to use 301 redirects for this purpose
>>
>> http://www.google.com/support/webmasters/bin/answer.py?answer=93633
>
> And to put this in a lasso context, [redirect_url] defaults to a 302
> redirect which will not be followed by search engines since it is
> considered a temporary move.
> Use [redirect_url: 'http://domain.com/new_url', -type=301] for a
> permanent redirect that will be followed by search engines.

In the context of redirecting from domain.tld to www.domain.tld, the Apache code below will do a 301 redirect for you, no Lasso code required:

    # add "www"
    RewriteCond %{HTTP_HOST} !^www\.domain\.tld$
    RewriteRule (.*)  <a href="http://www.domain.tld%">http://www.domain.tld%{REQUEST_URI} [L,NS,R=301]


- Bil


--
This list is a free service of LassoSoft: http://www.LassoSoft.com/
Search the list archives: http://www.ListSearch.com/Lasso/Browse/
Manage your subscription: http://www.ListSearch.com/Lasso/

12