2xx
204 No Content
The request succeeded but there is no content to return in the response body.
What is HTTP 204?
This status code indicates the server successfully processed the request but is intentionally not returning any content. The response may include updated headers, but the body must be empty. It is frequently used for DELETE operations, form submissions that do not navigate away, or save actions where no data needs to be sent back. The client should not change its current view or document, though it may update cached headers.
Defined in RFC 9110
Common Causes
- A DELETE request successfully removed a resource
- A PUT or PATCH request updated a resource and no body is needed in response
- A save or submit action completed but the client does not need new data
How to Fix
- No fix needed; the empty body is intentional
- If your client expects a response body, use 200 OK with a body instead
- Ensure your client-side code handles the empty response without errors