How to Take Your Website Down for Maintenance Without Losing Search Visibility
Objective
With the rapid increase in PHP patches created by potential hacks brought on by AI, it is becoming a common occurrence to take a website offline for hours and even days to administer a patch.
HTTP 503 Service Unavailable is the status code Google recommends for planned or emergency website downtime, because it tells Googlebot the outage is temporary and keeps already indexed pages in Google Search while the site is being fixed.
On October 21, 2026, the PHP project released emergency patches for two critical flaws that allow unauthenticated remote code execution, and on the same day Google Search Central posted a reminder on LinkedIn that "serving a 503 (Service Unavailable) HTTP status code ensures already indexed URLs are preserved in Search while you work." The timing reflects a broader pattern. Software vulnerabilities are being reported at a record rate, AI models are now part of how they are found and exploited, and more site owners will most likely need to take a site offline on short notice to patch it. How a site responds while it is offline decides whether Google, and the AI search features built on Google's index, treat the outage as a short pause or as a sign the pages are gone.
Key Facts
- Recommended status code: 503 Service Unavailable, for planned or emergency downtime.
- Responses to avoid during downtime: 404 Not Found, 500 Internal Server Error, timeouts, and a "back soon" page returned with a 200 OK status.
- Supporting header: Retry-After, set to a number of seconds or to a date and time.
- File that should not return a 503: robots.txt.
- Risk of a long outage: Google's crawl documentation says that if Googlebot sees these status codes on the same URL "for multiple days, the URL may be dropped from Google's index."
- Source of the guidance: Google Search Central documentation and its January 2011 post "How to deal with planned site downtime," which Google restated in October 2026.
Why Downtime Is Becoming More Common
- CVE volume: On April 15, 2026, the National Institute of Standards and Technology (NIST), which runs the US National Vulnerability Database, said that "submissions during the first three months of 2026 are nearly one-third higher than the same period last year" (The Record, April 15, 2026). The database is the main public record of known software vulnerabilities, so this is the clearest government measure of how fast new flaws are arriving.
- A record year before that: NIST said it enriched nearly 42,000 CVEs in 2025, 45% more than in any prior year (The Record, April 15, 2026). Enrichment is the work of adding severity scores and affected product details, and 2026 started above that record pace.
- The government is triaging: In the same statement, NIST said it will now fully process only CVEs on CISA's Known Exploited Vulnerabilities list, CVEs in software used by the federal government, and CVEs in software considered critical, and it will stop producing its own severity scores for every CVE (The Record, April 15, 2026). NIST acknowledged the new rules "may not catch every potentially high-impact CVE." For a site owner, this means less outside help deciding which flaws matter, and more pressure to patch quickly when a vendor issues a fix.
- AI finding flaws at scale: On April 7, 2026, Anthropic announced Project Glasswing, which gives a group of technology and security companies access to Claude Mythos Preview, a model built to find and exploit software vulnerabilities. Anthropic said the model had found thousands of vulnerabilities in real-world software, including a flaw in OpenBSD that had gone unnoticed for 27 years and a flaw in FFmpeg that had gone unnoticed for 16 years. Those are long-standing, widely used projects, which shows that AI is finding flaws in code that people and automated tools had already reviewed many times.
- Attackers using AI: In May 2026, Google Threat Intelligence Group reported that a criminal group's zero-day exploit for a popular open-source, web-based system administration tool showed signs of AI-assisted development, including a hallucinated CVSS score in the exploit script (Help Net Security, May 11, 2026). Google worked with the vendor to disclose the flaw before the planned mass exploitation campaign started.
- A web stack example: The October 2026 PHP flaws, CVE-2026-109618 and CVE-2026-109619, are each rated 9.2 on CVSS v4.0 and require no login or user interaction (Field Effect, October 2026). They are fixed in PHP 8.5.12, 8.4.27, 8.3.36, and 8.2.35, and updating plugins, themes, or the CMS does not fix them. For a WordPress site or any other PHP site, a fix like this happens at the server level and may need a restart or a maintenance window.
How to Take a Site Down Correctly
- Return a 503 for every page that is down: A 503 tells Googlebot the server is temporarily unable to handle the request, so Google keeps the indexed URL and comes back later. A 404 says the page does not exist, a 500 says something is broken without saying it is temporary, and a timeout gives Google nothing to work with. In October 2026, Google's John Mueller recommended that sites "use HTTP 503 instead of letting responses time out / 404 / 500."
- Never serve a maintenance page with a 200 status: A 200 tells Google the page loaded normally, so the maintenance message can be indexed in place of your real content. Mueller has said that an error page returned with a 200 status gets indexed as that error content. That message can then show up in your search snippets until Google recrawls the page.
- Add a Retry-After header: Set it to the number of seconds you expect to be down (3600 is one hour) or to the date and time you expect to be back. Google says Googlebot "may use" this value to decide when to recrawl, so treat it as a hint rather than an instruction. Use a realistic estimate, because a value that is too short brings crawlers back while the site is still down.
- Serve the 503 from outside the system you are fixing: For hardware maintenance, Google suggests serving the 503 from a separate server. Mueller made the same point in October 2026, saying the 503 can come from "outside of PHP / point DNS elsewhere / CDN." If PHP itself is the layer being patched, a 503 written in PHP code will not run. The common options are a maintenance rule in your CDN, a rule in the web server or load balancer that sits in front of the application, or a small separate server that DNS points to during the outage. If you use the DNS option, lower the DNS TTL a day ahead, because DNS changes take time to reach everyone.
- Write the 503 page for people: The status code is for crawlers, and the page content is for the people who arrive during the outage. Say what is happening in one or two plain sentences, give the time you expect to be back, and list another way to reach you, such as a phone number, an email address, or a status page.
- Keep robots.txt serving normally: Google's guidance on pausing a website says not to return a 503 for robots.txt, because that blocks all crawling of the site. Leave robots.txt on a 200 response with its normal content during the outage.
- Keep the scope as small as you can: Google's pausing guidance describes disabling a whole site as an extreme measure. If only checkout, login, or one application needs to be patched, return a 503 on those paths and keep your content pages online.
- Keep it short: In 2024, Google's Gary Illyes said a 503 lasting 10 to 15 minutes now and then "is not 'extended' by any means." Google's crawl documentation says it does not recommend 503s "for a long period of time," and its 2011 guidance says "lasting 503 HTTP result codes" can eventually be treated as a sign that the server is permanently unavailable. Google also slows crawling across the whole hostname when it sees many errors, then speeds back up on its own once the errors stop. Structured data and page metadata cannot be refreshed while pages return a 503.
A correct response during maintenance looks like this:
HTTP/1.1 503 Service Unavailable
Retry-After: 3600
Content-Type: text/html; charset=utf-8
Cache-Control: no-storeRetry-After can also be a date, such as Retry-After: Wed, 04 Nov 2026 14:00:00 GMT. The Cache-Control line keeps a CDN or browser from holding on to the maintenance page after the site is back up.
After the Site Comes Back
- Remove the maintenance rule and confirm 200 responses: Check a sample of important pages with the URL Inspection tool in Google Search Console or a header checker, because a forgotten CDN or server rule can keep returning 503s after the fix is done.
- Purge the CDN cache: This clears any copy of the maintenance page that was cached before the Cache-Control header took effect.
- Watch the Crawl Stats report: In Search Console, confirm that server errors drop back to zero and that crawl requests return to their normal level over the next several days.
- Check the Page indexing report: Look for URLs listed under "Server error (5xx)" over the following weeks, and request reindexing for important pages if any were dropped.
- Search for your maintenance message: Search your own domain for the text of your maintenance page to confirm it was not indexed in place of your content.
How AI Search Is Affected
Google's AI Overviews and AI Mode draw on Google's index, so a page that is dropped from the index after a long outage will most likely also drop out of the set of pages those features can cite. Other AI search crawlers, including those run by OpenAI, Perplexity, and Anthropic, do not publish downtime guidance as detailed as Google's. The HTTP standard (RFC 9110, IETF, June 2022) defines a 503 as a temporary condition and defines Retry-After as the way to say when to come back, so it is likely that well-built crawlers read a 503 the same way Googlebot does. That is likely behavior, not documented behavior, which is one more reason to keep outages short.
FAQ
What status code should a website return during maintenance?
A website should return a 503 Service Unavailable status code during maintenance. Google recommends it because it signals a temporary outage, so already indexed pages stay in Google Search while the site is down.
How long can a site return a 503 before Google drops its pages?
Google does not publish a fixed limit. A 503 lasting minutes to a few hours is generally safe, and Google's crawl documentation says that a URL returning a 503 for multiple days may be dropped from the index.
Should robots.txt return a 503 during maintenance?
No. Google's guidance on pausing a website says a 503 on robots.txt blocks all crawling of the site, so robots.txt should keep returning its normal content with a 200 status.
Does the Retry-After header control when Google recrawls?
No. Google says Googlebot may use the Retry-After value when deciding when to recrawl, so it works as a hint rather than a schedule.
What if the server or the software itself is what needs fixing?
Serve the 503 from somewhere else, such as a CDN maintenance rule, a load balancer, or a separate server that DNS points to during the outage. Google recommends a separate server for hardware maintenance, and a 503 written in application code will not run if that code is what is being patched.
Is a "back soon" page with a 200 status a problem?
Yes. A 200 status tells Google the page loaded normally, so the maintenance message can be indexed in place of the real content and can show up in search results.
Related
- @Rank Is the Only SEO Metric That Matters for AI Citation: why staying indexed and ranking is the base for being cited in AI answers.
- @Structured Data Standards for SEO and AI Search: Primary Sources and Measured Effect: the structured data that Google cannot refresh while pages return a 503.
- @AI Citations Rotate Daily, but Most Come Back: why citation tracking needs longer windows, which matters when reading visibility around an outage.
Subjective
The rate at which AI is finding new, severe software exploits means most of us are likely going to have to take a website down at some point to patch something, and probably with less notice than we would like. I do not think the patch is the part to worry about. The risk is what the site says to Google while it is offline, because a quick maintenance setup can easily show a friendly "back soon" page with a 200 status or let the server throw errors, and both send the wrong signal at the moment you can least afford it. As a practical rule, I plan for a 503 window of under four hours, and if a fix is going to run past 24 hours, I bring the content pages back online and keep the 503 only on the parts of the site that are still being worked on. Google's limits are looser than that, but I would rather not find out where they are with a client's site. My advice to a marketing leader is to have this conversation with your development team before there is an emergency: agree where the 503 is served from, what the Retry-After value will be, what the page will say, and who decides when it goes on and comes off. It is a five-minute job, and it can save you a very awkward week. Over the next 6 to 18 months, I expect patch windows to become a normal part of running a website, the same way backups are. If your team already has a maintenance plan, I would like to hear whether it says where the 503 is served from, because that is the detail that decides whether the plan works when the server itself is the problem.
