The TCP 3-way handshake

SYN, SYN-ACK, ACK: how two machines agree to talk before a single byte of data moves.

Before any data flows, TCP makes both sides prove they can hear each other. The client sends a SYN, the server answers with a SYN-ACK, and the client confirms with an ACK. Three messages, and now both sides know the line is live in both directions.

That tiny ritual is what makes TCP reliable: sequence numbers exchanged during the handshake let both machines detect lost or out-of-order packets for the rest of the conversation.

Remember this

  • Three messages: SYN, SYN-ACK, ACK
  • Both sides verify they can send AND receive
  • Sequence numbers from the handshake power reliability

Got a different question? SeaThru generates a fresh video for any topic where systems talk or data structures move.

Ask your own question →

Keep learning