// ports

Common TCP/UDP Ports Cheatsheet

The ports network engineers, NOC analysts and security teams actually see in tickets — with operational notes, not just IANA assignments.

Updated

Port reference

PortProtoServiceNotes
20/21TCPFTPData / control. Cleartext — avoid.
22TCPSSH / SFTPRemote shell, secure file transfer.
23TCPTelnetCleartext — disable wherever found.
25TCPSMTPServer-to-server mail relay.
53TCP/UDPDNSUDP for queries, TCP for AXFR / large responses.
67/68UDPDHCP67 server, 68 client.
69UDPTFTPOften used for switch/router image transfer.
80TCPHTTPPlain web — should redirect to 443.
110TCPPOP3Legacy mail retrieval.
123UDPNTPTime sync. Critical for auth/logs.
135TCPMS RPCWindows endpoint mapper.
137-139TCP/UDPNetBIOSLegacy SMB. Block at perimeter.
143TCPIMAPMail retrieval (cleartext).
161/162UDPSNMP161 polling, 162 traps. Use v3.
179TCPBGPBorder Gateway Protocol peering.
389TCP/UDPLDAPDirectory services (cleartext).
443TCPHTTPSTLS web. Most common open port today.
445TCPSMBWindows file sharing. Patch & restrict.
465TCPSMTPSSMTP over implicit TLS (legacy).
514UDPSyslogLog shipping to collector.
587TCPSMTP submissionAuthenticated mail submission with STARTTLS.
636TCPLDAPSLDAP over TLS.
993TCPIMAPSIMAP over TLS.
995TCPPOP3SPOP3 over TLS.
1194UDPOpenVPNDefault OpenVPN port.
1433TCPMSSQLMicrosoft SQL Server.
1521TCPOracle DBOracle TNS listener.
1723TCPPPTPLegacy VPN. Insecure.
2049TCP/UDPNFSNetwork File System.
3306TCPMySQLMySQL / MariaDB.
3389TCPRDPWindows remote desktop. Never expose to internet.
4500UDPIPsec NAT-TIKE traversal through NAT.
5060/5061TCP/UDPSIP / SIPSVoIP signaling.
5432TCPPostgreSQLPostgres database.
5900TCPVNCRemote desktop. Tunnel over SSH.
6379TCPRedisDefault cleartext. Bind to localhost.
8080TCPHTTP-altCommon dev/proxy port.
8443TCPHTTPS-altCommon admin UI port.
27017TCPMongoDBDefault cleartext. Authenticate.

FAQ

Which ports should never be exposed to the public internet?
RDP (3389), SMB (445), Telnet (23), database ports (1433, 3306, 5432, 27017, 6379), and SNMP (161). Put them behind a VPN or zero-trust proxy.
What's the difference between port 25, 465 and 587 for SMTP?
25 is server-to-server relay, 465 is legacy implicit-TLS submission, 587 is the modern submission port using STARTTLS with authentication. Use 587 for clients.
Why does DNS use both TCP and UDP?
UDP is used for normal queries (small, fast). TCP is used for zone transfers (AXFR/IXFR) and any response larger than 512 bytes (or 4096 with EDNS).

Related