Port 25: SMTP

Port 25 (TCP) is used by SMTP. This port is meant to be reachable publicly on servers that offer the service.

Updated

Port25
ProtocolTCP
ServiceSMTP
Internet exposureUsually open to the internet

Check if port 25 is open

What is port 25 used for?

Server-to-server email delivery. Mail servers receive messages from other mail servers on port 25.

Should port 25 be open?

Usually open to the internet. This port is meant to be reachable publicly on servers that offer the service. Only mail servers need 25 open inbound. Many home ISPs and cloud providers block outbound port 25 to stop spam, so apps should send mail through port 587 instead.

See what is listening on port 25

# Linux
sudo ss -tlnp | grep ':25 '

# macOS
sudo lsof -nP -i TCP:25 -sTCP:LISTEN

# Windows (PowerShell)
Get-NetTCPConnection -LocalPort 25 -State Listen

Open or block port 25 in a firewall

# Ubuntu / Debian (ufw)
sudo ufw allow 25/tcp
sudo ufw deny 25/tcp

# Windows (PowerShell, as administrator)
New-NetFirewallRule -DisplayName "Port 25" -Direction Inbound -Protocol TCP -LocalPort 25 -Action Allow

On cloud servers, also open the port in the provider’s security group or network firewall. At home, a service behind a router needs a port-forwarding rule to the device’s local IP.

Test it from outside

A port can be open on the server but blocked upstream. The Port Checker connects from the internet, so it shows what the world sees. From your own machine, use nc -vz example.com 25 (macOS/Linux) or Test-NetConnection example.com -Port 25 (Windows).

Port CheckerTest whether a server accepts connections on specific ports — web (80/443), mail (25/587/993), SSH, databases or remote desktop — and see which are open, closed or filtered by a firewall.
Open the tool

Frequently asked questions

What is port 25?
Server-to-server email delivery. Mail servers receive messages from other mail servers on port 25.
Is it safe to open port 25?
Usually open to the internet. This port is meant to be reachable publicly on servers that offer the service.
How do I check if port 25 is open?
Enter your domain or public IP in the Port Checker with port 25. It tries a TCP connection from the internet and reports open, closed or filtered.