Take the 2-minute tour ×
Webmasters Stack Exchange is a question and answer site for pro webmasters. It's 100% free, no registration required.

I have a WordPress site which is more content centric. Today, I found that certain URLs are getting indexed in Google Search results. They look like:

http://example.com/page/42/?referer=www.wwwdnal.com

The URL is not returning a 404 error but is displaying same content as in:

http://example.com/page/42/

I checked my entire site and haven't found any such links coming out of my site.

How to get rid of these?

share|improve this question
add comment

2 Answers 2

Use canonical URLs for your content pages. Then whenever Google crawls or find a link to one with the referrer in the query string it will automatically associate it with the canonical URL. The canonical URL will be the URL Google shows in the search results. It also prevents your site from appearing to have duplicate content.

share|improve this answer
    
To add to this, you can also inform Google what to do with certain URL query parameters in Google Webmaster Tools (i.e - don't index any URL's that contain ?referer) –  zigojacko Mar 25 at 14:47
add comment

Canonical is the correct way as suggested above. I would also remove this parameter from Google webmaster tools (canonical is not a directive but rather a suggestion as far as search engines are concerned, also - removing the parameters from WMT is a speedier solution). In WMT navigate to Crawl > URL Parameters > Configure URL parameters, then edit the referrer parameter to: doesn't affect page content.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.