HTTP 416 Range Not Satisfiable
HTTP 416 Range Not Satisfiable means the server cannot fulfill the byte range specified in the request's Range header. The range falls outside the bounds of the resource — typically because the requested start byte is beyond the end of the file. The server includes a Content-Range header with the actual resource size.
Quick reference
| Code | 416 |
|---|---|
| Name | Range Not Satisfiable |
| Category | 4xx Client Errors |
| Specification | RFC 9110 §15.5.17 |
| IANA status | Assigned |
| Cacheable | No |
| Client action | Check the Content-Range header for the actual resource size, then correct the range request. |
| In-depth guide | HTTP 416 full guide → |
What HTTP 416 means
RFC 9110 defines 416 as indicating that none of the ranges in the request's Range header field overlap the current extent of the selected resource or that the set of ranges requested has been rejected due to invalid ranges or an excessive request of small or overlapping ranges. A 416 response must include a Content-Range header with the current length of the resource: Content-Range: bytes */<length>.
The most common trigger: a resumable download client that recorded a file as partially downloaded at some byte offset, but the server-side file was deleted and replaced with a shorter version. The client requests bytes from offset X, but the new file ends before X, so the range is unsatisfiable.
Common causes
Resumable download after file change
A file download was interrupted and the client stored the byte offset. The file was updated or replaced on the server. The new file is shorter than the old one, so the stored offset is now beyond the end of the file. The client requests the range and gets 416.
Off-by-one in range calculation
Range headers use inclusive bounds: Range: bytes=0-999 requests bytes 0 through 999 inclusive (1000 bytes). If a 1000-byte file, the valid range is 0-999. Requesting 0-1000 for a 1000-byte file triggers 416 (byte 1000 does not exist).
Empty file
Any range request against a zero-byte file produces 416 — there are no bytes to satisfy any range.
Multiple ranges with invalid subset
A request with multiple ranges where at least one falls outside the file produces 416 for that range (or for the entire request, depending on server implementation).
How to fix a 416
- Read the Content-Range response header. It contains the actual file size:
Content-Range: bytes */52428800means the file is 52428800 bytes. Use this to validate your range. - For resumable downloads: restart from 0. If the file changed since you last downloaded part of it, the stored offset is invalid. Start the download fresh from byte 0.
- Validate range bounds. Ensure
end< file length. Use theContent-Lengthheader from a HEAD request to determine the file size before requesting ranges. - Handle 416 in download clients. When a resumable download receives 416, treat it as a signal to check whether the file changed (compare ETags) and restart if necessary.
FAQ
What does HTTP 416 Range Not Satisfiable mean?
HTTP 416 means the byte range you requested in the Range header falls outside the bounds of the resource. The server includes the actual resource size in the Content-Range response header.
How do I fix a 416 in a resumable download?
Check whether the file changed since you last downloaded part of it using the ETag. If the ETag changed, restart the download from 0. If not, verify your byte offset calculation — it may be off by one.
What does Content-Range: bytes */0 mean?
It means the resource is empty (0 bytes). Any range request against an empty file produces 416 with this header.
How is 416 different from 206?
206 Partial Content is the successful response to a valid range request. 416 is the failure response when the requested range falls outside the resource. Use the Content-Range header from the 416 to determine valid bounds, then retry with 206.
Related resources
On this site: HTTP 416 Range Not Satisfiable — full guide · HTTP 206 Partial Content · HTTP 400 Bad Request · All 4xx client errors
Standards: RFC 9110 §15.5.17 · IANA HTTP Status Code Registry · MDN Web Docs: 416