homepage Welcome to WebmasterWorld Guest from 54.205.168.88
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Home / Forums Index / Google / Google SEO News and Discussion
Forum Library, Charter, Moderators: Robert Charlton & aakk9999 & brotherhood of lan & goodroi

Google SEO News and Discussion Forum

    
Redirected domain few weeks ago, 301 Redirect showing in SERPS
joeking




msg:4662345
 3:53 pm on Apr 11, 2014 (gmt 0)

I have a website greenwidgets.com

I also have the domain name, green-widgets.com.

I did a 301 redirect of green-widgets.com a few weeks ago so that it points to greenwidgets.com.

Header Checker Tool says:
green-widgets.com 301 Moved Permanently
greenwidgets.com 200 OK

But new pages that are added to greenwidgets.com are now appearing in SERPS as green-widgets.com/page

Why would this be?

 

aakk9999




msg:4662348
 4:09 pm on Apr 11, 2014 (gmt 0)

Few weeks is normally too short for Google to process your redirects, but here I mean for the existing pages that you have redirected.

The way I understood your post is that after implementing redirect, new pages that are created and added to domain greenwidgets.com are shown as green-widgets.com.

This would not normally happen unless Google can somehow get that new page at the green-widgets.com domain, as Google would not know of it existing there if you added it to greenwidgets.com domain.

With regards to this new page, if you check green-widgets.com/page, do you see 301 to greenwidgets.com/page ?

Can you check your server logs to see that 301 redirects are being performed consistently, i.e. that there is no period where 200OK is returned for a page that should be redirected?

How are you linking internally? Have you changed all your internal links to link to greenwidget domain?

joeking




msg:4662374
 6:20 pm on Apr 11, 2014 (gmt 0)

That's correct - new pages are being listed as green-widgets.com/newpage.htm.

I have just put www.green-widgets.com into my browser and it goes to www.greenwidgets.com, but if I put green-widgets.com/newpage.htm it goes to green-widgets.com/newpage.htm. So no 301.

So what is happening is that only www.green-widgets.com is redirecting. Do I need to tick the wildcard box on the cpanel redirect? Or how do I fix this?

Somehow Google is seeing any new pages as related to green-widgets.com and not greenwidgets.com. I don't understand why. This new page was never on green-widgets.com and has only been uploaded to greenwidgets.com.

joeking




msg:4662427
 10:15 pm on Apr 11, 2014 (gmt 0)

Here's what my .htaccess shows:

RewriteCond %{HTTP_HOST} ^green\-widgets\.com$ [OR]
RewriteCond %{HTTP_HOST} ^www\.green\-widgets\.com$
RewriteRule ^/?$ "http\:\/\/www\.greenwidgets\.com\/" [R=301,L]

Is that correct?

Do I have to literally redirect each individual page or is there a catch all method? There are no pages from green-widgets.com that have the same file name in grenwidgets.com.

And how do I stop Google ranking green-widgets.com/page.htm instead of the genuine greenwidgets.com/page,htm?

Hope someone can help. This is driving me mad!

not2easy




msg:4662440
 10:46 pm on Apr 11, 2014 (gmt 0)

Your RewriteCond is capturing everything, the $ at the end will add in the page at the end of redirecting to the new domain - but the RewriteRule is not asking for the rest of the requested URL.

The URL side of the RewriteRule doesn't need to be escaped, but it does need the $ at the end to add the entire requested URL.
Try something like
RewriteRule ^(.*)$ http://www.example.com/$1 [R=301,L]
and see if that adds in the full URL.


Get rid of sitemaps you might have on the old site.

IF you have the old site in GWT, there are tools there to help you tell them what you are doing. Don't block robots until you handle the GWT changes.

Then to help keep Google from indexing the old site's pages set your robots.txt to disallow all bots:
User-agent: *
Disallow: /

Robots.txt does not prevent indexing, if the old links are found in links on other sites, and it can still take time to clean it all up.

I'm sure I skipped something, pretty sure others will be here fill in the blanks.

joeking




msg:4662444
 11:06 pm on Apr 11, 2014 (gmt 0)

Many thanks for the advice - it's much appreciated.

To be clear, I need to replace:

RewriteRule ^/?$ "http\:\/\/www\.green\-widgets\.com\/" [R=301,L]

with

RewriteRule ^(.*)$ http://www.example.com/$1 [R=301,L]

and that will prevent new pages that are added to the site (with file names that never appeared on the old domain) from appearing in the serps as olddomain.com/newpage.htm?

[edited by: aakk9999 at 1:58 am (utc) on Apr 12, 2014]
[edit reason] Examplified to avoid auto-linking [/edit]

not2easy




msg:4662466
 1:53 am on Apr 12, 2014 (gmt 0)

Not quite, it needs to add the captured information at the end, to add it to the redirect. The RewriteCond has $ at the end:
RewriteCond %{HTTP_HOST} ^www\.green\-widgets\.com$
to capture the entire request. Right now, the captured information is not being added on at the end. It looks like the rule isn't going to work, so it defaults to the original request on the old domain.

The example I gave you adds that $1 back on the end so it gets included in the resulting redirect. Try the same format, putting the actual new domain name where it says example.com:
RewriteRule ^(.*)$ http://www.example.com/$1 [R=301,L]

If someone visits green-widgets/small.html, the $1 adds the small.html part on to the URL in your RewriteRule after it rewrites the domain URL.

To keep it from forming a link here, we use "example.com" wherever we need to use a domain name.

joeking




msg:4662513
 8:20 am on Apr 12, 2014 (gmt 0)

Many thanks not2easy.

I did as you said, tested it, and all seems to be working correctly now.

Really appreciate your help.

not2easy




msg:4662584
 2:32 pm on Apr 12, 2014 (gmt 0)

Happy to hear that it works as you wanted.

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Google / Google SEO News and Discussion
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved