What is port in computer network?

Checked on January 6, 2026
Disclaimer: Factually can make mistakes. Please verify important information or breaking news. Learn more.

This fact-check may be outdated. Consider refreshing it to get the most current information.

Executive summary

A port in computer networking is a software-defined communication endpoint that lets multiple services share a single IP address by directing traffic to the correct process or application on a host [1][2]. Ports are identified by numeric port numbers (0–65535) and operate at the transport layer (TCP/UDP), enabling multiplexing, service identification and basic controls for security and firewalling [1][3].

1. What a port actually is: the logical doorbell for services

A network port is a virtual point where connections start and end—effectively a logical “doorbell” that tells an operating system which running process should receive incoming packets; it’s not a physical jack but a number bound to a transport protocol and an IP address to form a unique communication endpoint [2][1]. Ports appear in the transport-layer headers of TCP and UDP packets and are used by the OS to forward data to the correct application, which allows a single device to host a web server, email server and many other services simultaneously [4][5].

2. Port numbers, ranges and conventions: who decides which door is for what

Port numbers range from 0 to 65535 and are divided by convention into well-known (0–1023), registered (1024–49151) and dynamic/private (49152–65535) ranges; well-known ports such as 80 for HTTP and 443 for HTTPS are standardized through IANA and often require special privileges to bind on many systems [1][6]. These conventions let clients and servers agree where particular protocols listen, so web traffic reaches port 80/443 while DNS queries go to port 53, for example [2][7].

3. How ports work in practice: sockets, ephemeral ports and multiplexing

An application binds to a port via a socket, combining transport protocol, IP address and port number into a unique endpoint; client applications typically use ephemeral (temporary) source ports assigned by the OS while servers listen on fixed destination ports so multiple simultaneous sessions can coexist on the same host and IP [1][8]. This multiplexing function is central to the client–server model: many clients can open connections to the same server port and each session is distinguished by the tuple of source IP, source port, destination IP and destination port [1][3].

4. Security, scanning and operational implications

Because ports map traffic to services, they are a focal point for security—administrators close or firewall unused ports to reduce attack surface, while attackers often perform port scans to discover exposed services; techniques like port knocking and logging of connection attempts are used defensively and for access control [1][7]. Misconfigurations, open well-known ports, or services bound to unexpected ports can lead to vulnerabilities, so visibility into active ports (via tools like netstat) and strict privilege controls on binding well-known ports are common operational practices [9][1].

5. Ports in modern architectures: containers, cloud and microservices

In cloud-native environments, containers and microservices multiply the number of services and ephemeral endpoints, complicating port management and requiring orchestration to map container ports to host ports or to route traffic via service meshes and load balancers; accurate port configuration remains critical for performance, security and correct service discovery [7][3]. The underlying concept, however, remains unchanged: ports let many distinct services share network connectivity on the same address by providing distinct endpoints at the transport layer [5][2].

6. What ports are not — and the limits of the explanation

A network port is not a physical connector like a USB or HDMI jack despite sharing the word “port,” and it is distinct from “porting” software between platforms; the networking definition is specifically a logical/numbered endpoint in the transport layer [10][9]. Reporting across vendor glossaries, encyclopedias and security sites consistently frames ports as virtual connection points tied to TCP/UDP and assigned numbers, but deeper platform-specific behaviors (how an OS assigns ephemeral ports, privilege rules, or container port mapping) require consulting OS or orchestration documentation beyond these overviews [6][8].

Want to dive deeper?
How do TCP and UDP differ in their use of ports and session handling?
What are common security best practices for managing open ports on servers?
How do container orchestrators (Docker/Kubernetes) handle port mapping and service discovery?