All tools / Debug tools / Status codes
HTTP 204 No Content
The request worked and there is intentionally no body.
This page runs in your browser and makes no requests.
204 No Content
The request worked and there is intentionally no body.
Common causes
DELETE, PUT or a PATCH that doesn't need to return anything; a CORS preflight response.
What to do
Make sure the body really is empty and there's no Content-Length other than 0. A fetch client calling .json() on a 204 will throw.
Class: 2xx Success · Defined in RFC 9110 §15.3.5
How to use it
- Look at the response in your browser's Network tab, or run
curl -i URLto see the status line and headers. - Read the response body: many servers explain the exact reason there.
- Fix the cause above and send the request again.
Questions
Is 204 an error?
No. 204 is a success code.
Should I retry a 204?
No need: it worked.
Where can I see the 204 in my browser?
Open the developer tools (F12 or Cmd+Option+I), go to the Network tab, reload, and look at the Status column. Click the request and open the Response and Headers tabs for the details.
