# 503 Service Unavailable in WordPress

> A WordPress 503 is either core maintenance mode (a .maintenance file, 10 minute expiry) or your host. Check headers, clear a stuck update, and send Retry-After.

Canonical: https://scaplet.com/errors/http/503/wordpress

Guide WordPress Error · HTTP status codes

A WordPress 503 is either core maintenance mode (a .maintenance file, 10 minute expiry) or your host. Check headers, clear a stuck update, and send Retry-After.

5 min

read

7

sources

Oct 29, 2026

updated

Scaplet Editorial Team

author

503 5xx · Server error

The short answer

WordPress returns a 503 itself in one case: maintenance mode, triggered by a `.maintenance` file in the site root that WordPress ignores once it is 10 minutes old. The default page says "Briefly unavailable for scheduled maintenance. Check back in a minute." If the site is not in maintenance mode, the 503 is coming from a layer around WordPress, so read that layer's log.

1. [Where a WordPress 503 comes from](#where-a-wordpress-503-comes-from)
2. [Check it in 2 minutes](#check-it-in-2-minutes)
3. [Clear a stuck maintenance mode](#clear-a-stuck-maintenance-mode)
4. [Planned maintenance: send a 503 you control](#planned-maintenance-send-a-503-you-control)
5. [When it is not maintenance mode](#when-it-is-not-maintenance-mode)

30-second check

## Where does your site stand?

Four quick questions, then a straight answer.

1/4Have you checked your own site for this?

Summarize this page with [ChatGPT](https://chatgpt.com/?hints=search&q=Summarize%20https%3A%2F%2Fscaplet.com%2Ferrors%2Fhttp%2F503%2Fwordpress%20(%22503%20Service%20Unavailable%20in%20WordPress%22)%20in%205%20bullet%20points%2C%20then%20tell%20me%20the%20one%20thing%20I%20should%20do%20next.) [Claude](https://claude.ai/new?q=Summarize%20https%3A%2F%2Fscaplet.com%2Ferrors%2Fhttp%2F503%2Fwordpress%20(%22503%20Service%20Unavailable%20in%20WordPress%22)%20in%205%20bullet%20points%2C%20then%20tell%20me%20the%20one%20thing%20I%20should%20do%20next.) [Perplexity](https://www.perplexity.ai/search?q=Summarize%20https%3A%2F%2Fscaplet.com%2Ferrors%2Fhttp%2F503%2Fwordpress%20(%22503%20Service%20Unavailable%20in%20WordPress%22)%20in%205%20bullet%20points%2C%20then%20tell%20me%20the%20one%20thing%20I%20should%20do%20next.) [![Google](/logos/ai/google-color.svg)AI Mode](https://www.google.com/search?udm=50&q=Summarize%20https%3A%2F%2Fscaplet.com%2Ferrors%2Fhttp%2F503%2Fwordpress%20(%22503%20Service%20Unavailable%20in%20WordPress%22)%20in%205%20bullet%20points%2C%20then%20tell%20me%20the%20one%20thing%20I%20should%20do%20next.)

_01_Telling the sources apart

## Where a WordPress 503 comes from

The 503 that WordPress core sends on purpose is maintenance mode. Core checks for a `.maintenance` file in the WordPress root on each request. The file holds a `$upgrading` timestamp, and WordPress treats the site as in maintenance mode only if that timestamp is less than 10 minutes old. Updates write the file before they start and delete it when they finish, so a crashed update is the usual way a site gets stuck.

Source

### Core maintenance mode, default page

What you see

Plain page titled Maintenance, with the text "Briefly unavailable for scheduled maintenance. Check back in a minute."

How to confirm

A `.maintenance` file exists in the site root, and the response has `Retry-After: 600`

Source

### Custom maintenance.php drop-in

What you see

Your own page

How to confirm

A `wp-content/maintenance.php` file exists. Core loads it and ends the request, so it must send its own [status code](/glossary/http-status-codes)

Source

### Host, web server or PHP process

What you see

A host or server error page, often not styled like your theme

How to confirm

No `.maintenance` file, and the host or server error log shows the cause. See [503 in Apache](/errors/http/503/apache) or [503 in nginx](/errors/http/503/nginx)

Request path: which layer can return the 503

```
browser or crawler | v CDN / proxy (optional) -> 503 if it cannot reach the origin | v web server (Apache, nginx) -> 503 if it is overloaded or its backend is down | v PHP process (PHP-FPM, etc.) -> 503 if the host throttles or kills it | v WordPress core -> 503 only from maintenance mode
```

_02_Fix it on your stack

## Check it in 2 minutes

Commands marked as needing your site run against your own domain. The first two use a public test endpoint so you can see what the output looks like before you point them at anything real.

See what a 503 with Retry-After looks like (public test endpoint)
See what a 503 with Retry-After looks like (public test endpoint)

```
curl -sS -D - -o /dev/null https://httpbin.org/status/503 | head -n 1 # expected: HTTP/2 503 curl -sS -D - -o /dev/null "https://httpbin.org/response-headers?Retry-After=600" | grep -i retry-after # expected: retry-after: 600
```

Your own site: status line and Retry-After (needs your domain)
Your own site: status line and Retry-After (needs your domain)

```
curl -sS -D - -o /dev/null https://your-site.example/ | grep -i -E "^HTTP|^retry-after" # Core maintenance mode prints a 503 status line and: retry-after: 600 # A 503 without the default Retry-After was not sent by core's default maintenance page
```

Your own site: is core in maintenance mode? (needs SSH and WP-CLI)
Your own site: is core in maintenance mode? (needs SSH and WP-CLI)

```
wp maintenance-mode status # prints: Maintenance mode is active. (or the inactive message) wp maintenance-mode is-active; echo $? # exit code 0 means active, 1 means not active
```

I ran the first command pair against `httpbin.org` on 2026-11-01: the first returns `HTTP/2 503` and the second returns the `retry-after: 600` header. The WP-CLI output follows the examples in the WP-CLI command reference.

_03_How it works

## Clear a stuck maintenance mode

If the page has said "Check back in a minute" for longer than a few minutes, an update died halfway. Because WordPress ignores a `.maintenance` file older than 10 minutes, a stuck file usually clears on its own. If it does not, remove it yourself.

**The timestamp is the whole mechanism**A `.maintenance` file containing `<?php $upgrading = 1730000000; ?>` is read as a Unix time. Core's check also exposes an `enable_maintenance_mode` filter, so a plugin or must-use file can override whether the page shows. If maintenance mode keeps coming back after you delete the file, look for something recreating it, such as an update that keeps failing.

1. 01

### Deactivate with WP-CLI

Run `wp maintenance-mode deactivate`. The WP-CLI reference documents `activate`, `deactivate`, `is-active` and `status`.
2. 02

### Or delete the file

Connect with SFTP or SSH, open the WordPress root (the folder with `wp-config.php`) and delete `.maintenance`. Hidden files may need to be shown in your SFTP client.
3. 03

### Finish the interrupted update

Open Dashboard, then Updates, and rerun the update that stopped. An interrupted plugin or theme update can leave that item half-installed, so check it loads.
4. 04

### Recheck the headers

Run the `curl` check above. A 200 means the site is back.

_04_Your call

## Planned maintenance: send a 503 you control

The default page already sends `Retry-After: 600`. A custom `wp-content/maintenance.php` replaces that page, and core then requires the file and calls `die()`. Nothing in the source sends a status code for you on that path, so your file has to do it, otherwise visitors and crawlers can get a 200 for your maintenance page.

If this fits

### Use the default page when

- The downtime is an update that takes minutes
- You are happy with the plain core message
- The 600 second Retry-After is a fair estimate

Or

### Write maintenance.php when

- You want a branded page with contact details
- You want your own wording for a planned window
- You need a different Retry-After than 600 seconds

wp-content/maintenance.php

```
<?php http_response_code( 503 ); header( 'Retry-After: 3600' ); header( 'Content-Type: text/html; charset=utf-8' ); ?> <!doctype html> <title>Back soon</title> <h1>Scheduled maintenance</h1> <p>We are updating the site. Please check back in an hour.</p>
```

I ran this file through `php -l` (no syntax errors) and served it with PHP's built-in server: the response was `HTTP/1.1 503 Service Unavailable` with `Retry-After: 3600`. On a real site the drop-in only runs while `.maintenance` is fresh, so test by running `wp maintenance-mode activate`, checking the headers, then running `wp maintenance-mode deactivate`. For a full runbook, see [WordPress maintenance mode](/seo/wordpress/maintenance-mode).

_05_Next checks, by what you find

## When it is not maintenance mode

If `wp maintenance-mode status` says inactive and no `.maintenance` file exists, WordPress is not the layer returning the 503. Check the server first, because a 503 from a host often means a limit was hit before WordPress could run. WordPress's debugging guide documents `WP_DEBUG_LOG`, which writes PHP errors to `wp-content/debug.log`, and that log only helps if the request reached PHP.

Finding

### `debug.log` shows a fatal error naming a plugin or theme

Next step

Deactivate it: `wp plugin deactivate <plugin>`, or deactivate everything with `wp plugin deactivate --all` and re-enable one at a time

Finding

### `debug.log` shows `Allowed memory size of ... bytes exhausted`

Next step

Raise `WP_MEMORY_LIMIT` in `wp-config.php`, for example `define( 'WP_MEMORY_LIMIT', '96M' );`. The WordPress docs say the default attempt is 40MB for a single site

Finding

### `debug.log` is empty or missing for the failing request

Next step

The request never reached WordPress. Read the web server and PHP-FPM logs, then ask your host about resource limits

Finding

### The error page is not from your site at all

Next step

A CDN or proxy returned it. Test the origin directly, or see [503 in Apache](/errors/http/503/apache)

wp-config.php: log errors without showing them to visitors

```
define( 'WP_DEBUG', true ); define( 'WP_DEBUG_LOG', true ); define( 'WP_DEBUG_DISPLAY', false );
```

**Turn debug logging off afterward**The WordPress docs warn that error logs are often in a publicly accessible location. Delete the log and set `WP_DEBUG` back to false when you finish.

_06_Good to know

## What a WordPress 503 does to SEO

Google treats `500`, `503` and `429` as signals to slow crawling, and a 503 or 429 can carry a `Retry-After` header. Google's guidance for emergencies is that this is fine for a couple of hours up to 1-2 days. Its warning is that if [Googlebot](/ai-crawlers/googlebot) sees these status codes on the same URL for multiple days, the URL may be dropped from the index. So a normal update window is harmless, and a site stuck in maintenance for days is not. See [5xx server errors](/seo-issues/server-errors-5xx) for how to find affected URLs.

Catch a stuck 503 early

Scaplet's free audit at [/site-audit](/site-audit) reads status codes across your pages, so a site stuck on a 503 shows up as a status code problem instead of a silent traffic drop.

Sources · 7

## Every fact, linked and dated.

Official docs first. The date is when we last opened each page.

- wordpress.org
- google.com

1. 01 [WordPress Developer Resources: wp_maintenance()](https://developer.wordpress.org/reference/functions/wp_maintenance/) developer.wordpress.org · checked 2026-11-01
2. 02 [WordPress Developer Resources: wp_is_maintenance_mode()](https://developer.wordpress.org/reference/functions/wp_is_maintenance_mode/) developer.wordpress.org · checked 2026-11-01
3. 03 [WordPress Developer Resources: WP_Upgrader::maintenance_mode()](https://developer.wordpress.org/reference/classes/wp_upgrader/maintenance_mode/) developer.wordpress.org · checked 2026-11-01
4. 04 [WP-CLI: wp maintenance-mode](https://developer.wordpress.org/cli/commands/maintenance-mode/) developer.wordpress.org · checked 2026-11-01
5. 05 [WordPress Advanced Administration: Debugging in WordPress](https://developer.wordpress.org/advanced-administration/debug/debug-wordpress/) developer.wordpress.org · checked 2026-11-01
6. 06 [WordPress Advanced Administration: Editing wp-config.php](https://developer.wordpress.org/advanced-administration/wordpress/wp-config/) developer.wordpress.org · checked 2026-11-01
7. 07 [Google Search Central: Reduce the Google crawl rate](https://developers.google.com/crawling/docs/crawlers-fetchers/reduce-crawl-rate) developers.google.com · checked 2026-11-01

Questions

## Asked a lot.

3 questions people ask next, answered from the sources on this page.

_01_ How long does WordPress maintenance mode last?

WordPress treats the site as in maintenance mode only while the timestamp in the `.maintenance` file is less than 10 minutes old. After that, core considers maintenance over and serves the site normally, even if the file is still there.

_02_ How do I get WordPress out of maintenance mode?

Run `wp maintenance-mode deactivate` if you have WP-CLI, or delete the `.maintenance` file from the WordPress root with SFTP or SSH. Then rerun the update that was interrupted.

_03_ Does a custom maintenance page send a 503 automatically?

Not in WordPress core's code path. When `wp-content/maintenance.php` exists, core requires it and ends the request. Your file must set the 503 status and any `Retry-After` header itself.

## Keep learning

[All errors](/errors)

[Learn 503 Service Unavailable in nginx HTTP status codes](/errors/http/503/nginx) [Related 5xx server errors Status codes and links](/seo-issues/server-errors-5xx) [Read next 503 Service Unavailable HTTP status codes](/errors/http/503) [Do Run a free site audit Free, about two minutes](/site-audit)

Other 503 errors
[503 Service Unavailable in Apache](/errors/http/503/apache) [503 Service Unavailable in IIS](/errors/http/503/iis) [503 Service Unavailable in nginx](/errors/http/503/nginx) [503 Service Unavailable on Squarespace](/errors/http/503/squarespace) [ALB 503 Service Unavailable](/errors/cdn/alb-503)

Nearby in errors
[504 Gateway Timeout](/errors/http/504) [504 Gateway Timeout in Apache](/errors/http/504/apache)

More in 503 Service Unavailable
[503 Service Unavailable in Apache](/errors/http/503/apache) [503 Service Unavailable in IIS](/errors/http/503/iis) [503 Service Unavailable in nginx](/errors/http/503/nginx) [503 Service Unavailable in WordPress](/errors/http/503/wordpress) [503 Service Unavailable on Squarespace](/errors/http/503/squarespace)

Terms on this page
[HTTP status codes](/glossary/http-status-codes)

Free · 2 minutes

## Tools point. Agencies advise. _This one ships._

Run the free audit, then approve the fixes. Every change can be undone.

[Audit my site free](/site-audit)

Free, no card 60 seconds Nobody will call you

- **46** fixes shipped without a ticket Brightpipe
- **0→7** ChatGPT citations in six weeks Paylane
