1

Background

A server can send a Content-Encoding header to indicate if, and how, the content of the response body has been compressed. E.g.

Content-Encoding: gzip

A server can also send a Content-Type header to indicate the media type, and optionally provide the standard used to encode the content. E.g.

Content-Type: text/html; charset=utf-8

Therefore, it seems that the encoding of the content is specified in the Content-Type header, and not the Content-Encoding header.


Question

During the design of the HTTP standard, what's the rationale behind the naming of the Content-Encoding header? (Over, say Content-Compression) Is this a similar case of bad naming like the 401 Unauthorized response code?

dayuloli
  • 16,205
  • 16
  • 71
  • 126

0 Answers0