Visual RFC.
ALL RFCs / RFC 6455
Read the RFC ↗
RFC 6455 / EXCHANGE MESSAGES

Fragments and control frames

04

A large message can be fragmented while Ping and Pong remain responsive between fragments.

RFC 6455 · § 5.4EXAMPLE
3 / 3
03
Finish the original message.

The final continuation completes the text message in fragment order.

Fragments and control framesAn unfinished text message receives a Ping/Pong control exchange between fragments, then a final continuation completes the original text.Control between message fragmentsIllustrative message: Hellotext · FIN=0Helmessage incompletePing: 7Pong: 7continuation · FIN=1loAssembled text: HelloAppend the final continuation in order

Key idea: Keep control frames independent from message fragments.

Terms

Look up a term in the glossary ↗

Rules & examples
  • A fragmented message begins with text/binary and FIN=0, continues with opcode 0, and ends with FIN=1.
  • Control frames cannot be fragmented and have at most 125 payload bytes. They may appear between message fragments.
  • A Ping normally requires a Pong response with the same application data, unless a Close was already received.

Without an extension defining it, fragments of different data messages are not interleaved. An unsolicited Pong is permitted and does not require a response.

Sources
Protocol participantThreat or exceptionProtocol controlSimplified drawings · precise section references
New to this? Start hereA quick picture + helpful background

A request starts a conversation.

A client asks for a resource. A server sends a response. The method, address, headers, and status explain what that conversation means.

Helpful first, if these ideas are unfamiliar

These pictures are analogies to help you learn. The linked RFC explains the actual rules.

Related RFCs and changes

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

All chapters in RFC 6455

Drawing view

Scroll the drawing to see every part. Playback controls stay above it.

RFC 9700 / CHAPTERS

Chapters

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

RFC status and corrections ↗