100% Free Forever
AI-Powered Learning
Industry Expert Content
Certificates & Badges
Learn At Your Own Pace
Computer Science

UDP

IntermediateProtocol6.6K learners

UDP (User Datagram Protocol) is a lightweight, connectionless transport-layer protocol that sends data packets, called datagrams, without establishing a connection or guaranteeing delivery, ordering, or duplicate protection.

Definition

UDP (User Datagram Protocol) is a lightweight, connectionless transport-layer protocol that sends data packets, called datagrams, without establishing a connection or guaranteeing delivery, ordering, or duplicate protection.

Overview

UDP is one of the two core transport protocols in the internet protocol suite, standing in contrast to TCP/IP. Where TCP prioritizes reliability through handshakes, acknowledgments, and retransmissions, UDP strips all of that away, simply firing packets toward a destination address and moving on. This minimal design means far less overhead and lower latency, but also no built-in guarantee that a packet arrives, arrives only once, or arrives in the order it was sent. This trade-off makes UDP well suited to applications where speed and low latency matter more than perfect reliability, or where the application layer can handle its own error correction. Real-time voice and video calls, for example, would rather drop a stale packet than wait for a retransmission that arrives too late to be useful. Online multiplayer games similarly favor UDP so that the most current player position always wins over an outdated retransmitted one. Because UDP has no connection state, it is also simpler and cheaper to scale for certain patterns — DNS lookups (see DNS Resolution) typically use UDP for their small, single-round-trip queries, and many streaming protocols and IoT sensor networks build directly on top of it. Some modern protocols, such as QUIC (which underlies HTTP/3), layer their own reliability and congestion control on top of UDP to get both low latency and application-level guarantees. Choosing between TCP and UDP is a foundational decision in network application design, closely tied to the broader Client-Server Architecture of a system.

Specification

  • Connectionless — no handshake required before sending data
  • No guarantee of delivery, ordering, or duplicate prevention
  • Minimal header overhead compared to TCP
  • Lower latency, well suited to real-time applications
  • Commonly used for DNS queries and streaming media
  • Forms the base layer for newer protocols like QUIC
  • Application layer is responsible for any needed reliability

Use Cases

Real-time voice and video calling applications
Online multiplayer gaming with frequent position updates
DNS query and response exchanges
Live video and audio streaming
IoT sensor data transmission where occasional loss is acceptable
Foundation for modern protocols like QUIC and HTTP/3

History

The User Datagram Protocol was designed by David P. Reed and formally defined in RFC 768, published on August 28, 1980. UDP is a minimal, connectionless transport protocol: it lets applications send datagrams with no connection setup and no guarantees of delivery, ordering, or duplicate protection, offering only an optional checksum for integrity. That simplicity is deliberate — by omitting TCP's reliability machinery, UDP achieves very low overhead and latency, which makes it the transport of choice for real-time and loss-tolerant workloads such as DNS queries, streaming media, online games, and VoIP. The specification has remained essentially unchanged since 1980, a testament to the durability of its design.

Sources

Frequently Asked Questions