Link to home
Start Free TrialLog in
Avatar of Brian Sowter
Brian Sowter

asked on

WWW redirect confused

I have run a SEO website audio which throws up "WWW redirect" error. (see attachment)  My home page is called index.php and my registered domain is www.sowter.co.uk.    If I put sowter.co.uk into my browser (Chrome) it automatically changes it to www.sowter.co.uk.  I dont know how or why?  Do I need to add anything to my home page.  Is this a problem or not?
www_sowter_co_uk_2015_09_25.pdf
Avatar of Dave Baldwin
Dave Baldwin
Flag of United States of America image

I went to 'sowter.co.uk' in both Firefox and Chrome and did Not get redirected to 'www.sowter.co.uk'.  I don't think you need to do anything.  I'm not sure why you are seeing that in your copy of Chrome.

Wish I could afford some of your transformers.
I just looked at the links on your home page.  All of them use http://www.sowter.co.uk so the minute you click on any of them, you will be seeing 'www' in your browser address bar.  If you are using 'sowter.co.uk' in your SEO, you should probably change it to 'www.sowter.co.uk' since that what all of your links are.
Its not that he has Seo'd on a different domain, it's that the site will operate as two sites in Google's eyes.

If you have access to the Apache conf files, then use the Alias directive to fix this.

If your sure definition is www.domain.com, then you'll use:

Alias domain.com

 As the directive. (Or vice versa)

If you don't have access, then put a 301 redirect in an .htaccess file in the root.
Avatar of Brian Sowter
Brian Sowter

ASKER

Thanks for this. Could you please let me have  sample code for the .htaccess file?
The htaccess code to force into www. version of your site:
RewriteCond %{HTTP_HOST} !^$
RewriteCond %{HTTP_HOST} !^www\. [NC]
RewriteRule ^ http://www.%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

Open in new window

+1 for Lucas' post.
Sorry Guys but I am more confused than ever.
I have attached a screen clip from my Google dashboard showing 2 URL,s. I suppose the idea is that people can find us with and without the www .  I think this is causing the problem.  Should I delete one of them.
Dashboard-clip.pdf
Sorry but that isn't causing any problems.  One day a couple of years ago, Google decided to create separate listings for with and without 'www'.  I have a bunch of those and they make no difference at all.  If you delete one, it should be the one without 'www' since all your links include 'www'.
Dave
Thanks for this.  I have asked the people who wrote the SEO tool I am using about this question.  I am going to wait and see what they say but it is looking as though this is red herring.
ASKER CERTIFIED SOLUTION
Avatar of Dave Baldwin
Dave Baldwin
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Brilliant!  Thanks.
I shall now have to learn about UTF-8!  Never a dull moment.
Sorry, just checked back in on this. The original issue you identified is a problem.

Your site should not render separately as:
http://www.sowter.co.uk
http://sowter.co.uk

One of those domains needs to redirect to the other one.

In Google's eyes currently these are two different sites, with duplicate content. If Google considers your content to be duplicated, it can hurt your rankings. There are two things you need to do:

1.

Set your preferred domain in search console

2.

Integrate the 301 redirect via the htaccess code specified previously in this thread
I have done the search console bit.  Now I have access to server file manager. I cant find a file called .htaccess

Should I create one and if so where do I put it?  I attached a list of the folders on the host.

This is the code:  is it correct?

# And for a site running on port 80
RewriteCond %{HTTP_HOST}   !^www\sowter.co.uk [NC]
RewriteCond %{HTTP_HOST}   !^$
RewriteRule ^/(.*)         http://www.sowter.co.uk/$1 [L,R]
host-files.pdf