Networking · Concept

Ports

Numbers that pick out which program on a machine should receive incoming data: the IP address finds the building, the port finds the flat.

Network basics · updated

How it works

A port is a number from 0 to 65535 attached to every TCP or UDP connection. Common services have agreed defaults: 80 for HTTP, 443 for HTTPS, 22 for SSH, 53 for DNS, 587 for sending email and 5432 for PostgreSQL. A server listens on its port, and a firewall decides which ports can be reached from outside.

Numbers below 1024 are the well-known range, and on Linux opening one needs admin rights. Port forwarding on a router sends traffic that arrives on a public port to a device inside the network. Leaving admin ports such as 22 (SSH) or 3389 (Windows Remote Desktop) open to the whole internet invites a constant stream of automated login attempts.

More in Networking

Network basics

All 11 Networking terms

Crafted in the dark. Shipped to the world.

Tell us what you are building. You get a private project space with a proposal and a line-by-line quote within a day.