5 Protocols, Services, and Ports
Learn how network protocols, services, and port numbers work together, and review the behavior and common port assignments of key networking protocols.
How protocols, services, and ports fit together
Protocols define how networked systems communicate. A service is a function provided to applications, such as resolving a domain name or delivering a web page. IP addresses help deliver traffic to the right host, while or numbers help deliver it to the right service on that host.
A connection or flow is commonly identified by its source and destination IP addresses and numbers, together with the transport protocol.
and transport
(Transmission Control Protocol) provides a connection-oriented, reliable, ordered byte stream. It uses acknowledgments and retransmission to recover from lost data, making it suitable when complete, correctly ordered delivery matters. Web traffic using /1.1 or /2 and many email connections commonly use .
(User Datagram Protocol) sends independent datagrams with less transport-level machinery. It does not guarantee delivery, ordering, or duplicate protection, although applications may add reliability themselves. queries and commonly use ; real-time applications may also choose it to avoid waiting for retransmissions.
Both and have numbers. A server typically listens on a known destination , while a client commonly uses a temporary source for its request and reply traffic.
Core protocols and services
and
(Domain Name System) resolves names such as example.com to data such as IP addresses. generally uses 53 for queries and responses. It uses 53 when a connection is needed, including for some large responses and zone transfers.
(Dynamic Host Configuration Protocol) automatically provides hosts with configuration such as an IP address, subnet mask, default gateway, and server. In the familiar IPv4 exchange, a client sends from 68 to a server on 67. A common sequence is Discover, Offer, Request, Acknowledge (DORA).
Web protocols
(Hypertext Transfer Protocol) transfers web resources using a request-and-response model. Its conventional is 80.
is protected with TLS, which provides encryption and authentication for the connection. Its conventional is 443. /3 carries over QUIC, which uses 443.
Network control messages
(Internet Control Message Protocol) carries network-layer control and error messages rather than application data addressed through or ports. Tools such as ping use Echo Request and Echo Reply messages. has no numbers.
Common ports and their limits
Common and transport assignments include:
ports
20and21: FTP data and control, respectively, in traditional active FTP.22: SSH remote access.25: SMTP mail transfer between servers.and
53: queries and other traffic.ports
67and68: server and client, respectively, for IPv4.80: .110: POP3 email retrieval.123: NTP time synchronization.143: IMAP email access.ports
161and162: SNMP requests and notifications, respectively.443: ;443is also used for /3 over QUIC.
numbers are conventions and registrations, not proof of what a device is actually running. Services can be configured to use other ports, and traffic on a familiar is not automatically safe.
IANA divides numbers into System Ports, from 0 through 1023; User Ports, from 1024 through 49151; and Dynamic/Private Ports, from 49152 through 65535. Client operating systems commonly select temporary ports from the dynamic range.