HTTP: The Response

W3C HTTP 1992

Response

The response from the server shall start with the following syntax (See also: note on client tolerance ):

  <status line>   ::=    <http version>  <status code>  <reason line> <CrLf>
  <http version>  ::=    3*<digit>
  <status code>   ::=    3*<digit>
  <digit>         ::=    0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9
  <reason line> ::=   * <printable>


<http version>
identifies the HyperText Transfer Protocol version being used by the server. For the version described by this document version it is "HTTP/1.0" (without the quotes).
< status code >
gives the coded results of the attempt to understand and satisfy the request. A three digit ASCII decimal number.
<reason string>
gives an explanation for a human reader, except where noted for particular status codes.

Fields on the status line are delimited by a single blank (parsers should accept any amount of white space). The possible values of the status code are listed below .

Response headers

The headers on returned objects those RFC822 format headers listed as object headers , as well as any MIME conforming headers, notably the Content-Type field. Note that this specification doesnot define any headers particular to the response which are not also apropriate to any transmission of an object with a request.

Response data

Additional information may follow, in the format of a MIME message body. The significance of the data depends on the status code.

The Content-Type used for the data may be any Content-Type which the client has expressed its ability to accept, or text/plain, or text/html. That is, one can always assume that the client can handle text/plain and text/html.