Will this have an SEO impact?

Compound

Shufflin'
Jan 15, 2010
406
9
0
I'm blocking / redirecting certain country IPs via htaccess. Will this hurt my rankings in the unblocked countries?
 


Be careful of the redirects. They can get you in trouble. Also, make sure you always let Googlebot through. Other than that, you should be fine in the unblocked areas.

If you are targeting a specific location you can identify a location within Google's webmaster tools.
 
No, blocking IP address of certain country will not harm your website in target countries. SE engines respect the fact that due to certain reasons IP addresses gt banned and thus it does not impact your rankings in any way.
 
Thanks very much for the feedback.

I was basically looking to block the bots that kept hitting the site daily. Nearly all of the spam comments were captured by akismet. The real issue was that the bots were also clicking on links and throwing off my stats.

Rather than blocking the non-US IPs, here's the solution I found (added this .htaccess):

Code:
RewriteEngine On
RewriteCond %{REQUEST_METHOD} POST
RewriteCond %{REQUEST_URI} .wp-comments-post\.php*
RewriteCond %{HTTP_REFERER} !.*mysiteurl.com.* [OR]
RewriteCond %{HTTP_USER_AGENT} ^$
RewriteRule (.*) http://%{REMOTE_ADDR}/$ [R=301,L]
My understanding is that bots without a referer (which is typically the case), will be blocked.