Port 25 is the original SMTP port for server-to-server email delivery. Many ISPs block outbound port 25 to prevent spam. Authenticated email submission uses port 587 (STARTTLS) or port 465 (SMTPS). Mail servers that receive email still listen on port 25.
Port Number
25
Protocol
TCP
Service
Simple Mail Transfer Protocol
Range
IANA Well-Known (0–1023)
Test basic SMTP connectivity and banner
telnet mail.example.com 25Test STARTTLS support on port 25
openssl s_client -connect mail.example.com:25 -starttls smtpFind which servers receive mail for a domain
dig MX example.com +shortSend a test email via SMTP (Swiss Army Knife for SMTP)
swaks --to [email protected] --from [email protected] --server mail.example.com:25telnet mail.example.com 25
EHLO sender.example.com
MAIL FROM:<[email protected]>SMTP was defined in RFC 821 (1982) by Jon Postel. The current version is RFC 5321 (2008). The protocol was designed for an era of trusted networks – authentication was added later via SMTP AUTH (RFC 4954). Port 587 for authenticated submission was standardized in RFC 6409 (2011).
Why do ISPs block outbound port 25?
Compromised home computers (botnets) send spam directly via port 25. ISPs block it at the network level to prevent residential IPs from being blacklisted. Legitimate users send via port 587 (authenticated submission) through their provider's mail server.
Do I need port 25 open to SEND email?
No. Sending (submission) uses port 587 with authentication. Port 25 is only needed INBOUND for servers that RECEIVE email from other mail servers. Your application should connect to your SMTP relay on 587, not 25.