HTTP 204 — No Content
2xx Success
What it means
The request succeeded and there is deliberately no body to return. Common for DELETE and for PUT that returns nothing.
What to do about it
Do not send a body with a 204 — some clients will error. If you want to return the updated resource, use 200 instead.
Where it sits
204 belongs to the 2xx family: The request was received, understood and accepted.
HTTP/1.1 204 No Content
Checking it yourself
# see the status code and headers only
curl -sI https://example.com/path
# follow redirects and print each hop
curl -sIL -o /dev/null -w "%{http_code} %{url_effective}\n" https://example.com/path
# JavaScript
const r = await fetch(url);
console.log(r.status, r.statusText);
How this code behaves
| Cacheable by default | Yes — per RFC 9110, this status is cacheable unless headers say otherwise. |
| Safe to retry | Not applicable. |
| Effect on search indexing | No direct effect. |
Returning 204 correctly
# nginx
return 204;
# Express
res.status(204).end();
# Go
w.WriteHeader(204)
# Python (Flask)
return '', 204;
Frequently asked questions
What does HTTP 204 mean?
The request succeeded and there is deliberately no body to return. Common for DELETE and for PUT that returns nothing.
How do I fix a 204 error?
Do not send a body with a 204 — some clients will error. If you want to return the updated resource, use 200 instead.
Is 204 a client or server problem?
Neither — it indicates success or progress.