Common causes
- Too much traffic for the available servers, or a connection or worker limit has been reached.
- Planned maintenance or a deploy in progress.
- A load balancer or ingress has no healthy targets: every backend failed its health check, or none are registered.
- In Kubernetes, the Service has no ready endpoints because the pods are crashing or their readiness probes fail.
- A rate limiter or circuit breaker that answers with 503 instead of 429.
Where to look
| Setup | Check |
|---|---|
| Kubernetes / ingress | kubectl get endpoints <service> should list pod IPs. If it's empty, check kubectl get pods and the readiness probe. |
| AWS load balancer | Target group health in the console. A 503 from the load balancer means no healthy targets. |
| Envoy or a service mesh | no healthy upstream in the response body means the same: every backend is failing its checks. |
| nginx | The error log, and any limit_req or limit_conn rules, which return 503 by default when a limit is hit. |
Returning 503 for maintenance
Tell clients and search engines that the outage is temporary and when to come back:
HTTP/1.1 503 Service Unavailable
Retry-After: 600
Content-Type: text/html
<h1>Down for maintenance</h1>
<p>We'll be back in about 10 minutes.</p>Frequently asked questions
Does a 503 hurt my search rankings?
A short 503 with Retry-After is the recommended way to signal planned downtime, and Google will come back later. If pages return 503 for days, they can start dropping out of the index.
What is the difference between 503 and 502?
502 means the upstream sent a bad response. 503 means the service can't take requests at the moment, often because there's no healthy upstream at all or it's deliberately refusing load.
Should my API retry on 503?
Yes, with exponential backoff and jitter, and respect Retry-After when it's there. Retrying immediately in a tight loop adds load to a service that's already struggling.
More http status code lookup guides
- 502 Bad Gateway: What It Means and How to Fix It
- 504 Gateway Timeout: Causes and Fixes
- 429 Too Many Requests: Meaning, Retry-After and Fixes
- 403 Forbidden: Meaning, Causes and How to Fix It
- 401 Unauthorized: What It Means and How to Fix It
- 500 Internal Server Error: Causes and How to Fix It
- 400 Bad Request: Causes and Fixes (Including Cookie Too Large)
- 404 Not Found: What It Means and How to Fix It
- 301 Moved Permanently: Meaning, SEO and Examples
- 302 Found: Temporary Redirects Explained
- 408 Request Timeout: Causes and How to Fix It