RFC 822 Message Format

The Internet RFC 822 specification defines an electronic message format consisting of header fields and an optional message body. The header fields contain information about the message, such as the sender, the recipient, and the subject. If a message body is included, it is separated from the header fields by an empty line (\r\n).

The following example illustrates a message in the RFC 822 message format:

From: someone@example.com
To: someone_else@example.com
Subject: An RFC 822 formatted message

This is the plain text body of the message. Note the blank line
between the header information and the body of the message.

The RFC 822 message format is the basis for other message formats. The following example illustrates the Usenet article/message format specified by RFC 850:

From: someone@<yourcompany>.com
Subject: A basic RFC 850 formatted message
Newsgroups: comp.<yourcompany>.test

The body of this message is plain text. Note the blank line
between the header information and the body of the message.