Is there a HTTP status code to tell Google (and others) to go away, index me again later?
Basically, one that semantically tells clients that the site is down for maintenance?
The ones I have considered are
304 => Not modified
307 => Temporary redirect
410 => Gone
503 => Service Unavailable
I’m leaning towards the last one, but was just curious as to which one was proper choice.
HTTP 503 – Service Unavailable would be the most appropriate.
This post on the Google Webmaster Central Forum is also relevant:
UPDATE:
As for the php implementation, you may be interested in checking out the following article:
Also notice the
retry-afterheader, where you can specify after how many seconds another request should be re-attempted.