If-Range
If-Range makes a range request conditional on a validator — if the selected representation is unchanged, honor the accompanying Range request; otherwise, send the entire current representation.
Technique Definition
If-Range makes a range request conditional on a validator. Informally, it means: if the selected representation is unchanged, honor the accompanying Range request; otherwise, ignore Range and send the entire current representation instead. Under Existence Oracle analysis, If-Range is not a primary source of a new differential, but a validator-gated refinement that controls whether range semantics stay active.
Primary Headers / Methods
Request Headers
If-RangeRange
Representation Metadata It Relies On
ETagLast-ModifiedContent-Range
Primary Method Context
GETwithRange
Secondary Method Context
- None for RFC-defined use.
If-Rangeis only meaningful when paired withRange.
Can Elicit
Primary Differential Role
- Does not define a standalone existence differential in the same clean way as
Range,If-None-Match, orIf-Match.
Adjacent / Supporting Outcomes
206when the validator matches and the server honorsRange200when the validator does not match and the server ignoresRange- Indirect support for
206 vs 404where the existing target reaches range evaluation and the nonexistent target bottoms out at404
Stage Role
Under this taxonomy, If-Range is best treated as a range-gating refinement rather than as the canonical trigger for a separate differential.
Best Use
If-Range is best used when the goal is to test whether a server will continue partial-transfer behavior only if the client's validator still matches the current representation.
For Existence Oracle analysis, it is most useful as a scoped follow-on to Range, because it can show that the server located a representation, evaluated a validator, and then decided whether to preserve or collapse range semantics.
Why It Works as an Existence Trigger
When If-Range is evaluated on an existing target, the server must compare the supplied validator against the current selected representation before deciding whether to honor Range. If the condition is true, the server should process the range request and can return 206 Partial Content. If the condition is false, the recipient must ignore Range, which ordinarily collapses the response into a full-representation 200 OK branch instead of a range-specific result.
That behavior is existence-relevant because it depends on representation-aware validator evaluation, but it is less clean as a standalone oracle because the false branch is not a precondition failure and does not create a sharp RFC-defined status split like 304, 412, or 416.
Method Applicability
GET
- Primary and only meaningful RFC-defined method context.
If-Rangeonly matters when the request is also aRangerequest, and range handling is defined only forGET.
HEAD
- Not a valid core
If-Rangemethod context. - Without active
Rangeprocessing,If-Rangehas no RFC-defined elicitation role.
Other Methods
- Not meaningful for this technique under RFC 9110.
If-Rangeshould not be treated as a general conditional-request trigger outsideGET+Range.
Trigger Strength / Normative Level
Client-Side Constraints
- A client MUST NOT send
If-RangewithoutRange. - A client MUST NOT send a weak entity tag in
If-Range. - A client MUST NOT send an HTTP-date unless it has no entity tag and that date is a strong validator.
Server / Recipient Behavior
- A server that receives
If-Rangeon a range request MUST evaluate the condition before performing the method. - If the condition evaluates false, the recipient MUST ignore the
Rangeheader field. - If the condition evaluates true, the recipient SHOULD process the
Rangerequest as requested.
Practical Result
This gives If-Range strong normative footing for validator evaluation, but weaker oracle cleanliness than the other techniques because its false branch usually becomes 200 rather than a dedicated failure code.
Validator Forms
Entity-Tag Form
- Must use exact strong comparison against the current
ETag. - Weak entity tags are not allowed here.
HTTP-Date Form
- Uses exact match against
Last-Modified, not the "earlier than or equal to" logic used byIf-Unmodified-Since. - This makes the date form stricter and often less forgiving.
Consequence
If-Range is a precise range-gating validator, not a general freshness check.
Portability Notes
If-Rangeis most portable when used with a strongETag.- The false branch commonly becomes
200 OK, which is less distinctive for existence work than304,412, or416. - Because
If-Rangedepends onRange, any server behavior that ignoresRangealso weakens this technique. - This technique proves validator-aware range gating, not that a shared cache exists or that prior responses were stored.
Detection Notes
- Establish a known-existing target and a known-nonexistent target.
- Use
GETwith bothRangeandIf-Range. - Supply a validator chosen to test either the matching branch or the non-matching branch.
- Compare whether the existing target preserves
206behavior or collapses into a full-response branch. - Treat this as a supporting technique, not the cleanest primary existence oracle.
Relationship to Other Techniques
Versus Range
Rangeis the primary range-evaluation trigger.If-Rangeis the refinement that decides whetherRangesurvives validator checking.
Versus If-Match
If-Matchblocks the method on a false condition and can lead to412.If-Rangedoes not block the method that way; it falls back by disablingRange.
Versus If-Unmodified-Since
If-Unmodified-Sinceuses precondition semantics.If-Rangeuses range-gating semantics and exact validator matching.
Scope & Limitations
- It does not prove that a shared cache is present.
- It does not prove that a prior response was stored in an intermediary.
- It does not prove freshness lifetime, cache keying, or cache hits.
- It does not create a clean standalone status differential on its own.
- It only proves that RFC-defined validator-gated range handling was evaluated when the server actually applies it.
Range
Range alters a GET request so the client asks for only one or more subranges of the selected representation instead of the entire representation.
Negotiation Elicitation
Negotiation elicitation techniques use proactive negotiation request headers to force the server into representation-selection paths that diverge based on target existence.