Compare your production SMTP port with the host's block list
Read the port from the production config, not your local env file. DigitalOcean blocks 25, 465 and 587 on Droplets. Hetzner blocks 25 and 465. Compute Engine blocks 25 to external destinations.
Docs: docs.digitalocean.com →
Check whether a new-account restriction applies
On Linode, some accounts created after 5 November 2019 can't send over the standard SMTP ports until support lifts the restriction. Check your account age and the provider's notice before you change any code.
Docs: techdocs.akamai.com →
On Hetzner, send through an external delivery service on port 587
Hetzner does not block port 587 on cloud servers, so you need no limit request. Point the mailer at your external delivery service's submission port.
SMTP_PORT=587
Docs: docs.hetzner.com →
On Compute Engine, move off port 25 to 587 or 465
Port 25 to destinations outside your VPC network is blocked. Google Cloud places no restrictions on traffic to external destinations on TCP ports 587 or 465.
Docs: docs.cloud.google.com →
On DigitalOcean, send through a third-party email service
Switching to 587 won't help on a Droplet, because 25, 465 and 587 are all blocked. DigitalOcean recommends a third-party email service provider for mail sent from services it hosts.
Docs: docs.digitalocean.com →
Request an unblock where the host offers one
On Hetzner, after a month and a paid first invoice, file a limit request that describes a valid use case. On Linode, contact support with your name, use case, sending practices and the domains you will send from.
Docs: docs.hetzner.com →