Visual RFC.
ALL RFCs / RFC 5322
Read the RFC ↗
RFC 5322 / EMAIL MESSAGE FORMAT

Folding long fields

02

One logical header field can span physical lines at permitted folding white space.

Related RFCs and changes

“Updates” changes part of an earlier RFC. “Obsoletes” replaces it. This list shows selected related documents.

RFC 5322 · § 2.2.3EXAMPLE
3 / 3
Folding long fieldsOne logical header field can span physical lines at permitted folding white space.Physical lines, one logical fieldLOGICAL FIELDSubject: Planning the next releasefoldSubject: Planningthe next releaseCRLFleading WSPunfoldSubject: Planning the next release78 recommended · 998 maximum · excludes CRLF
03
Unfold on receipt.

Remove the folding CRLF before interpreting the logical field.

Protocol participantThreat or exceptionProtocol controlSimplified drawings · precise section references
KEY POINT

Unfold before interpreting a field.

  • Lines must not exceed 998 characters; 78 is the recommended limit, excluding CRLF.
  • Unfolding removes CRLF immediately followed by white space.
DETAILS

A display wrap is not necessarily a legal wire-format fold. Reject header injection.

Read the RFC section ↗

Diagrams simplify the RFC. Read the linked sections for complete requirements.

Privacy
All chapters in this RFC
  1. Message anatomy
  2. Folding long fields
  3. Mailboxes and groups
  4. Authors, senders, and recipients
  5. Message IDs and reply threads
  6. Trace, resending, and trust
RFC 9700 / CHAPTERS

Chapters

For full details, tables, algorithms, and exceptions, read the original RFC.

RFC status and corrections ↗