Intermediate Topic 20 of 50 Computer Networks
UDP
Lightweight connectionless transport without delivery guarantees.
How it works
The User Datagram Protocol sends independent datagrams with minimal overhead: an 8-byte header with ports, length and a checksum. It offers no handshake, no retransmission, no ordering and no congestion control, so datagrams may be lost, duplicated or reordered. This makes it fast and lightweight, and well suited to broadcast and multicast.
Step-by-step walkthrough
- The sender builds a small datagram.
- It is sent with no handshake.
- No acknowledgements come back.
- A lost datagram is simply gone.
- This is fast and ideal for video calls, games and DNS.
Where it is used
DNS queries, video and voice calls, online games, streaming, DHCP, NTP and protocols like QUIC built on top of UDP use it. Applications that need timeliness more than perfect reliability prefer it.
Common pitfall
Applications must handle loss and ordering themselves if needed. Without congestion control, a UDP sender can flood the network. Datagrams larger than the path MTU get fragmented or dropped. UDP can be abused for amplification attacks and spoofed source addresses. Keep messages small and add application-level acknowledgements where required.
Where it fits in the course
UDP is topic 20 of 50 in Computer Networks, rated Intermediate. It follows TCP. The next topic is Three-Way Handshake.
Practice and explore
- Open the interactive lesson, with a mini quiz.
- Take the Computer Networks quiz.
How to study this topic
- Read the explanation above and restate the definition in your own words.
- Open the interactive lesson and answer its mini quiz.
- Read the common pitfall, then write a short example that avoids it.
- Check your understanding in the Computer Networks quiz, and revisit the topic if you miss a question.
Frequently asked questions
What is UDP?
Where do people use UDP?
What is the most common mistake with UDP?
What should I learn before this topic?
How can I practice it?
Is UDP hard to learn?
How long does it take to learn UDP?
Which topics are related to UDP?
What should I study after UDP?
Related topics
- TCP (Computer Networks)
- Three-Way Handshake (Computer Networks)
- Wi-Fi (Computer Networks)
- Flow Control (Computer Networks)