Port
A computer "port" has three primary meanings: a physical hardware port (like a USB or HDMI jack) for connecting devices; a network port (a virtual, numbered endpoint) that directs internet traffic to specific applications on a computer; and the process of porting software, which involves adapting a program to run on a different platform.
Hardware port
Description: A physical connection point on a computer where an electrical connector can be plugged in to link it with external devices.
Function: Transfers data, power, or signals between the computer and peripherals like monitors, keyboards, printers, and external storage.
Examples: USB, Ethernet, HDMI, DisplayPort, and Thunderbolt.
Network port
Description: A virtual communication endpoint for sending or receiving data on a computer network, identified by a unique number (port number).
Function: Allows a computer to differentiate between different types of network traffic, ensuring that data for a specific service (like web browsing or email) is sent to the correct application on the device.
How it works: Works in conjunction with an IP address to pinpoint a specific service on a specific device. For example, HTTP traffic typically uses port 80, while HTTPS traffic uses port 443.