If you are using apache (this gives free access to google bot and asks any other user for a password):
Require valid-user
Allow from <google_ip_range1> <google_ip_range2> ...
Satisfy Any
(details here: httpd.apache.org/docs/current/mod/mod_access_compat.html)
Getting Google IP address ranges might be tricky:
support.google.com/webmasters/answer/80553?hl=en
|