IM

The HTTP IM response header indicates the instance-manipulations applied to the response instance before delivery.

Usage

The IM header works within the delta encoding framework. When a client sends an A-IM request header listing acceptable instance-manipulations, the server applies one or more transformations to the stored instance and responds with a 226 IM Used status code. The IM header lists the manipulations applied, in the order they were performed.

Delta encoding reduces bandwidth by transmitting only the differences between two versions of a resource instead of the complete body. The Delta-Base header identifies the base version the delta was computed against, letting the client reconstruct the full response by applying the delta to its cached copy.

When multiple manipulations appear in the IM header, the order is significant. The server applies each manipulation sequentially, and the client reverses them in the opposite order to recover the original instance.

Note

Responses carrying an IM header use the 226 IM Used status code. A server returning only a byte range without other manipulations omits the IM header and uses 206 Partial Content instead.

Values

vcdiff

A delta encoded using the VCDIFF binary format. VCDIFF is the most common delta encoding format for HTTP.

diffe

A delta produced by the UNIX diff -e command, generating an ed-script representation of the differences.

gdiff

A delta using the Generic Diff Format (GDIFF) encoding.

gzip

The standard gzip Compression, applied as an instance-manipulation rather than a content-coding.

deflate

The standard deflate compression, applied as an instance-manipulation.

range

Indicates the result is partial content selected by a byte range. When range appears alongside other manipulations, the IM header lists all of them to preserve ordering. The response includes a Content-Range header or a multipart/byteranges Content-Type with per-part Content-Range headers.

identity

A token used only in the A-IM request header (not in IM) to signal acceptance of unmodified instances.

Example

A server returns a delta-encoded response using VCDIFF. The client combines the delta with its cached version of the resource to reconstruct the current representation.

HTTP/1.1 226 IM Used
IM: vcdiff
Delta-Base: "abc123"
Content-Length: 1024

A server applies multiple manipulations in sequence: first a diffe delta encoding, then deflate compression, then byte range selection. The client reverses the operations in opposite order.

HTTP/1.1 226 IM Used
IM: diffe, deflate, range
Content-Range: bytes 0-999/5000

Takeaway

The IM header declares the instance-manipulations a server applied to a response, enabling delta encoding and bandwidth-efficient transfers in coordination with the A-IM request header and the 226 IM Used status code.

See also

Last updated: March 6, 2026