Skip to content
← All Status Codes
411
Client Error

411 Length Required

The server refuses the request because the Content-Length header is missing.

Definition (RFC 9110)

HTTP status code 411 411 Length Required is defined in RFC 9110 (HTTP Semantics), Section 15.5.12 — the current authoritative specification for HTTP semantics, published June 2022, which obsoletes the older RFC 7231 and RFC 2616.

Description

411 Length Required indicates that the server will not accept the request without a valid Content-Length header. Some servers require this header to allocate resources before processing the request body, particularly for large file uploads or streaming data.

Common Causes

  • HTTP client not sending Content-Length with POST/PUT requests
  • Chunked transfer encoding where server doesn't support it
  • Misconfigured HTTP library or custom HTTP client

How to Fix

  • Add the Content-Length header with the correct byte count of the request body
  • If using chunked encoding, verify the server supports Transfer-Encoding: chunked
  • Update your HTTP client library to automatically set Content-Length

Check your website's HTTP status code

Check now →

Related Status Codes

Automate this check

Set up continuous monitoring and get an alert when something breaks. No manual runs to remember.