PortChecker Logo
PortChecker

Port 25 — SMTP (TCP)

SMTP

What is Port 25?

심플 메일 전송 프로토콜

This is a well-known port (0–1023) commonly used by core services like SMTP.  ·  RFC 5321

When do you need Port 25 open?

Open only on mail servers that receive email from other mail servers (MX record). ISPs typically block port 25 on residential connections. Use port 587 for sending from applications or mail clients.

Common uses and software

  • Postfix
  • Exim
  • Sendmail
  • Microsoft Exchange Server
  • Haraka

보안

Port 25 is exploited by spammers when misconfigured as an open relay. Require STARTTLS for all connections. Enable SPF, DKIM, and DMARC DNS records to prevent spoofing. ISPs block port 25 on residential connections — use a dedicated mail server or relay service (SendGrid, Mailgun) if sending bulk email.

Is Port 25 safe?

An open port increases your attack surface. Safety depends on how SMTP is configured.

High risk

This port is actively targeted by automated attacks. Keep it closed unless SMTP is actively required, and restrict access to known IP ranges in your firewall.

Check Port 25 now

Test connectivity for Port 25 on any host.

1-65535

How to Open Port 25

To allow incoming connections to Port 25 (SMTP) from outside your network, configure your firewall and add a port forwarding rule on your router pointing to your device's local IP address.

Windows Firewall

Open Windows Defender Firewall → Advanced Settings → Inbound Rules → New Rule → Port → TCP → Specific local ports: 25 → Allow the connection → Name and save the rule.

netsh advfirewall firewall add rule name="Open Port 25" dir=in action=allow protocol=tcp localport=25
Linux (UFW / iptables)sudo ufw allow 25/tcpsudo iptables -A INPUT -p tcp --dport 25 -j ACCEPT
Router

Log into your router (192.168.1.1 or 192.168.0.1) → Port Forwarding → Add a new rule: Protocol TCP, External port 25, Internal IP: your device's local IP, Internal port 25 → Save.

How to close Port 25

If you do not need SMTP, block this port in your firewall or router.

Windows Firewall

To block port 25 on Windows, run the following command in PowerShell or Command Prompt (as Administrator):

netsh advfirewall firewall add rule name="Block Port 25" dir=in action=block protocol=tcp localport=25
Linux (UFW / iptables)sudo ufw deny 25/tcpsudo iptables -A INPUT -p tcp --dport 25 -j DROP
Router

Remove or disable any port forwarding rule for Port 25.

Frequently Asked Questions

What is Port 25 used for?▾

Port 25 is the default TCP port for SMTP. It is used by servers and applications that need to accept incoming connections for this service. Whether you need it open depends on whether you are actively running a SMTP server — if not, it should remain closed to reduce your attack surface.

Is Port 25 safe to keep open?▾

An open Port 25 increases your attack surface. If you are not actively running SMTP, close this port in your firewall and remove any port forwarding rules. If SMTP must be accessible, restrict access to known IP ranges, keep the service software updated with security patches, and use strong authentication.