Domain 1.5 | Network Fundamentals — 20% of exam
Learning Objectives
By the end of this lesson, you will be able to:
- Explain the TCP three-way handshake and what it actually establishes
- Compare how TCP and UDP handle reliability and packet ordering
- Compare the overhead each protocol imposes, and why that overhead exists
- Match common applications to the transport protocol they actually use, and explain why
Key Terms
| Term | Definition |
|---|---|
| TCP | Transmission Control Protocol; connection-oriented, reliable, ordered delivery |
| UDP | User Datagram Protocol; connectionless, no delivery or ordering guarantee |
| Three-way handshake | The SYN, SYN-ACK, ACK exchange that establishes a TCP connection |
| Acknowledgment (ACK) | A signal confirming data was received, used by TCP to detect loss |
| Sequence number | A number TCP assigns to data, used to detect loss and reorder arrivals |
| Retransmission | TCP resending data it never received an acknowledgment for |
| Connectionless | No setup exchange before data is sent — UDP just sends |
Explanation
One Question, Every Application Answers It Differently
Speed or reliability. Pick one.
That’s not quite true — it’s a spectrum, not a binary — but it’s close enough to be useful. Every application built on top of IP has to answer this question, whether its developers thought about it explicitly or not: is it worse to lose some data, or worse to wait for it? TCP and UDP are the two answers. This lesson covers both, and — more usefully — covers why specific applications land where they do.
This lesson builds on interface and cable issues. That lesson covered problems at the physical and data-link layers. TCP and UDP operate one layer up, at the transport layer — and a lot of what looks like a “network problem” at that layer is actually just TCP or UDP behaving exactly as designed.
TCP: Connection-Oriented, and What That Actually Means
TCP doesn’t just start sending data. It sets up a connection first, through a specific three-step exchange called the three-way handshake.
SYN. The initiating device sends a segment with the SYN flag set, along with an initial sequence number it’s chosen. This is effectively “I want to talk, and here’s where my counting starts.”
SYN-ACK. The receiving device responds with both its own SYN (proposing its own sequence number) and an ACK acknowledging the first device’s SYN. Two things happening in one segment. Efficient.
ACK. The initiating device acknowledges the second device’s SYN. Handshake complete. Both sides now agree the connection exists, and both know the other’s starting sequence number.
Three steps, and notice what they actually accomplish — this isn’t just ceremony. Both ends confirm the other side is actually reachable and listening, before either commits to sending real data. And both ends agree on starting sequence numbers, which is what makes reliability and ordering (covered next) possible at all.
Worked example, made concrete: think about calling someone on the phone. You dial, it rings, they pick up and say “hello” — that’s roughly SYN and SYN-ACK. You respond “hey, it’s me” — that’s the ACK. Only after that brief exchange does the actual conversation start. Nobody launches into their message before confirming someone’s actually on the line. TCP works the same way, for the same reason.
Termination gets a mention too, briefly, since it’s a fair extension of this concept. TCP closes a connection with a similar four-step exchange — FIN, ACK, FIN, ACK — each side independently signaling it’s done sending. This isn’t separately tested in depth at CCNA level, but understanding that TCP is deliberate about closing a connection, not just opening one, reinforces the larger point: TCP treats the connection itself as a real, managed thing, not just a sequence of packets sent and hoped for.

UDP: Connectionless, and Why That’s a Feature, Not a Flaw
UDP skips all of that. No handshake. No setup exchange. A device with data to send just sends it, addressed to the destination, and moves on.
This sounds like UDP is simply “worse” — missing a feature TCP has. It isn’t missing anything. It’s a deliberate design choice for applications where the handshake’s cost isn’t worth its benefit. Every round trip in that three-way handshake takes time. For an application sending one small query and expecting one small answer, that setup overhead can be a meaningful fraction of the entire transaction’s total time. UDP eliminates it entirely.
Common misconception: people sometimes describe UDP as “TCP without reliability,” as if it’s TCP with pieces removed. Better framing: TCP and UDP are two separate, complete designs, built for two different priorities from the ground up. UDP isn’t a broken or incomplete TCP. It’s a different, equally intentional answer to the same underlying question.
Reliability: How TCP Actually Guarantees Delivery
TCP’s reliability isn’t magic. It’s a mechanical process, built on the sequence numbers established during the handshake.
Every byte TCP sends gets a sequence number. The receiving side sends back an acknowledgment confirming what it’s received. If the sender doesn’t get an ACK within an expected window of time, it assumes that data was lost — and resends it. That’s retransmission, and it’s the entire mechanism behind “guaranteed delivery.” Not a guarantee in the sense that loss never happens on the wire — loss happens constantly, on every real network — but a guarantee that TCP will notice the loss and correct for it before the application above it ever sees a gap.
UDP does none of this. No sequence numbers tracked for reliability purposes, no acknowledgments, no retransmission. If a UDP datagram gets lost in transit, UDP doesn’t know, doesn’t care, and does nothing about it. Whatever application sent that data either doesn’t need it retransmitted, or handles that need itself, entirely outside of UDP’s scope.
Worked example: downloading a file over TCP, and one segment gets lost somewhere in transit. The receiving side notices a gap in the sequence numbers it’s received, and eventually the sender notices the missing ACK and resends that specific segment. The file arrives complete — the application never even knows a segment was lost along the way, because TCP handled it transparently underneath.
Now picture that same loss happening during a live video call over UDP. The lost packet is simply gone. The video might stutter or briefly glitch for a frame. Nobody retransmits it — by the time a retransmission could even arrive, the moment it represented has already passed. Reliability would actually make this worse, not better, since a stalled live call waiting for a retransmitted frame from a second ago is far more disruptive than a brief glitch.
Ordering: Why Sequence Numbers Do Double Duty
Here’s something worth understanding explicitly: IP packets can arrive out of order. Not a rare edge case — a genuinely normal occurrence, since different packets between the same two devices can take different physical paths through the network, hit different amounts of queuing delay at different routers along the way, and simply arrive in whatever order they happen to arrive in.
TCP’s sequence numbers, the same ones used for reliability, also solve this. The receiving side uses them to reassemble data in the correct order regardless of the order packets actually arrived in, buffering out-of-order segments until the gaps are filled and a complete, correctly-sequenced stream can be handed up to the application.
UDP provides no such guarantee. If UDP datagrams arrive out of order, they’re delivered to the application in whatever order they arrived — out of order, if that’s how it happened. Applications that genuinely need ordering while using UDP have to implement that logic themselves, above UDP, since UDP itself won’t do it for them.

Overhead: The Real Cost of All That Reliability
None of TCP’s reliability and ordering machinery is free. It costs bytes, and it costs processing.
A TCP header runs a minimum of 20 bytes — sequence numbers, acknowledgment numbers, flags, window size, checksum, and more, all needing space in every single segment. A UDP header, by contrast, is a lean 8 bytes: source port, destination port, length, and checksum. Nothing else. TCP also requires each side to actively maintain connection state — tracking sequence numbers, managing timers for retransmission, tracking window sizes for flow control — for the entire life of the connection. UDP maintains no state at all between one datagram and the next; each one is independent, with nothing remembered from the last.
This overhead is exactly why the speed-versus-reliability trade-off is real, not just theoretical. TCP’s guarantees cost bandwidth, cost processing on both ends, and cost the latency of the handshake itself before any real data even moves. For applications where that cost buys something genuinely necessary — a downloaded file has to be byte-perfect — it’s worth paying. For applications where speed matters more than perfection, it’s pure cost with no offsetting benefit.
Matching Applications to the Right Protocol
This is where the comparison becomes genuinely practical rather than abstract.
TCP’s typical users: web browsing (HTTP/HTTPS), file transfer (FTP), and email (SMTP). Notice the pattern — in every one of these, missing or corrupted data is a real, unacceptable problem. A webpage missing part of its content is broken. A downloaded file missing bytes is corrupted and often unusable. An email missing part of its text has lost information the sender actually meant to send. Reliability isn’t optional here. It’s the entire point.
UDP’s typical users: voice calls, video streaming, and DNS queries. Look at the pattern here instead — these are all applications where a small amount of loss is tolerable, and where speed and low latency matter more than perfection. A dropped voice packet causes a barely-noticeable, momentary glitch. Waiting for that packet to be retransmitted would cause a much more noticeable, disruptive delay in a live conversation — the fix would be worse than the problem.
DNS deserves a specific, slightly more nuanced note. DNS typically uses UDP for standard queries — small request, small response, speed matters, and if a query is lost, the resolver simply times out and asks again, which is cheap and fast. But DNS can fall back to TCP for larger transactions specifically — most commonly zone transfers between DNS servers, which involve larger volumes of data where TCP’s reliability genuinely matters more than UDP’s speed. This is worth knowing precisely because it shows the choice isn’t always fixed per-protocol — sometimes the same overall service uses different transport protocols for different parts of its own job, based on what each specific transaction actually needs.
Worked example, tying the whole lesson together: imagine streaming a live sports broadcast. Video and audio data flow over UDP — speed matters enormously for a “live” experience, and if a frame gets dropped, a barely-noticeable glitch is far preferable to the stream visibly pausing to wait for a retransmission. But the same streaming platform’s website — the page listing available broadcasts, letting you log in, processing your subscription payment — runs over TCP via HTTPS, because every one of those interactions genuinely needs to be complete and correct. Same overall service. Two different transport protocols, chosen deliberately for two different jobs within it.


TCP & UDP Practice Quiz
Test your knowledge of TCP handshakes, reliability, sequence numbers, packet ordering, UDP, DNS, and transport-layer protocols.
Summary
- TCP is connection-oriented, established through the SYN, SYN-ACK, ACK three-way handshake before any real data is sent.
- TCP guarantees delivery through acknowledgments and retransmission; UDP provides no such guarantee and doesn’t track loss at all.
- TCP’s sequence numbers also solve out-of-order arrival, a normal consequence of packets taking different paths through the network; UDP delivers datagrams in whatever order they arrive.
- TCP’s reliability costs real overhead — a larger header and ongoing connection state — that UDP avoids entirely.
- The underlying trade-off is speed versus reliability, and applications choose deliberately: TCP for web browsing, file transfer, and email; UDP for voice, video, and DNS queries — with DNS itself sometimes using both, depending on the specific transaction.