Why ports need a range structure at all
A port number identifies a specific service or connection endpoint on a device, alongside its IP address — since two unrelated applications on the same machine both need the network stack to route traffic to the correct one, ports need to be assigned in some organized way to avoid different services silently colliding on the same number. The Internet Assigned Numbers Authority (IANA) manages this via three bands across the full 16-bit (0–65535) range.
The three ranges
| Range | Name | Purpose |
|---|---|---|
| 0–1023 | Well-known ports | Reserved for widely used, standardized system services |
| 1024–49151 | Registered ports | Assignable to specific applications/vendors by request, less strictly enforced |
| 49152–65535 | Dynamic/private ports | Used for temporary, ephemeral connections — not permanently assigned to any service |
Well-known ports: the ones worth memorizing
| Port | Protocol | Transport | Service |
|---|---|---|---|
| 20, 21 | FTP | TCP | File transfer (20 data, 21 control) |
| 22 | SSH, SFTP, SCP | TCP | Secure remote shell and file copy |
| 23 | Telnet | TCP | Unencrypted remote shell (avoid) |
| 25 | SMTP | TCP | Mail between servers |
| 53 | DNS | UDP, TCP | Name lookups (TCP for large replies and zone transfers) |
| 67, 68 | DHCP | UDP | Address assignment (67 server, 68 client) |
| 69 | TFTP | UDP | Trivial file transfer, network boot |
| 80 | HTTP | TCP | Unencrypted web traffic |
| 88 | Kerberos | TCP, UDP | Authentication (Active Directory) |
| 110 | POP3 | TCP | Mail download |
| 123 | NTP | UDP | Time sync |
| 135 | MS RPC | TCP | Windows RPC endpoint mapper |
| 137–139 | NetBIOS | UDP, TCP | Old Windows file and name services |
| 143 | IMAP | TCP | Mail access |
| 161, 162 | SNMP | UDP | Device monitoring (162 for traps) |
| 179 | BGP | TCP | Routing between networks |
| 389 | LDAP | TCP | Directory lookups |
| 443 | HTTPS | TCP (UDP for HTTP/3) | Encrypted web traffic |
| 445 | SMB | TCP | Windows file sharing |
| 465 | SMTPS | TCP | Mail submission over TLS |
| 514 | Syslog | UDP | Log collection |
| 587 | SMTP submission | TCP | Mail from clients to their server (STARTTLS) |
| 636 | LDAPS | TCP | LDAP over TLS |
| 993 | IMAPS | TCP | IMAP over TLS |
| 995 | POP3S | TCP | POP3 over TLS |
Registered ports you will meet anyway
These are above 1023, so technically registered rather than well-known, but they come up just as often:
| Port | Service |
|---|---|
| 1433 | Microsoft SQL Server |
| 1521 | Oracle Database |
| 3306 | MySQL, MariaDB |
| 3389 | Remote Desktop (RDP) |
| 5432 | PostgreSQL |
| 5900 | VNC |
| 6379 | Redis |
| 8080, 8443 | Alternative HTTP and HTTPS (proxies, dev servers) |
| 27017 | MongoDB |
Look up any other number with the port number lookup.
Who may use ports below 1024?
On Linux and other Unix systems, only root (or a process with the CAP_NET_BIND_SERVICE capability) may listen on ports below 1024. The idea is that a service on a low port was started by the administrator, so an ordinary user cannot impersonate SSH or a web server on a shared machine. Windows has never had this restriction, and macOS dropped it in 10.14 (Mojave). It is also why development servers default to ports like 3000 or 8080, which need no special rights.
Dynamic/private ports: where your browser's outgoing connections live
When your browser opens a connection to a web server on port 443, it does not connect from port 443. The operating system picks a temporary, or ephemeral, port as its own end of that connection and releases it when the connection closes. That is why network tools show random high port numbers for outgoing connections.
IANA reserves 49152–65535 for this, and Windows (since Vista) and macOS follow it. Linux does not: its default range is 32768–60999, set by net.ipv4.ip_local_port_range. A service listening on, say, port 40000 on Linux can therefore clash with outgoing connections, so avoid that range for servers. On Windows, check the range with netsh int ipv4 show dynamicport tcp.
Common mistakes
- Assuming every port below 1024 is actually in active standardized use. Many well-known-range numbers are formally reserved but rarely seen in practice — the range is a reservation ceiling, not a claim that all 1024 slots are meaningfully assigned.
- Trying to bind an unprivileged process directly to a well-known port and being surprised by a permissions error — this restriction is deliberate, not a bug.
- Confusing the port a server listens on with the port a client's outgoing connection uses. A web server listens on 443; the client's side of that same connection uses an arbitrary dynamic-range port, not 443 itself.
FAQ
Why do I need administrator privileges to run a server on port 80 or 443?
On Linux and other Unix systems, ports 0–1023 can only be opened by root or a process with CAP_NET_BIND_SERVICE, so ordinary users cannot impersonate standard services. Windows and macOS 10.14+ do not restrict them. On Linux, run the server behind a reverse proxy, grant the capability with setcap, or listen on 8080 and forward.
What port does my browser use when it connects to a website?
The server listens on a well-known port (usually 443), but the browser's end of the connection is a temporary port the operating system picks: from 49152–65535 on Windows and macOS, and from 32768–60999 by default on Linux.
Are all ports below 1024 actually assigned to a real, active service?
No — the well-known range is a reservation ceiling recognized by IANA; many specific numbers within it are formally reserved but rarely encountered in everyday use.
Look up any port number's registered use with the Port Number Lookup — entirely client-side.
Use the CIDR / Subnet Calculator to explore a related subnetting example. For a related walkthrough, read HTTP Status Codes: The Five Classes.