a month ago
We have a .NET application deployed on Railway trying to connect to an external SMTP server.
Target:
Host: mail.plain.pt
Port: 587
TLS: STARTTLS
The application times out while opening the TCP connection:
Connecting to SMTP server mail.plain.pt:587 using StartTls with timeout 15s
Failed to send email after 15000ms
ErrorType=System.TimeoutException
Stack: MailKit.Net.SocketUtils.ConnectAsync / SmtpClient.ConnectAsync
The SMTP provider confirms:
- ports 465 and 587 are open;
- SMTP service is active;
- no connection attempts reached their server at the tested timestamps.
Could you help us?
1 Replies
a month ago
Your workspace is on the Hobby plan, and outbound SMTP is only available on the Pro plan and above. This is why the TCP connection to mail.plain.pt:587 times out and no connection attempts reach the remote server. You can either upgrade to the Pro plan (and redeploy your service afterward) or switch to a transactional email service that uses HTTPS APIs, such as Resend, SendGrid, or Postmark. More details are in our outbound networking docs.
Status changed to Awaiting User Response Railway • about 1 month ago
Status changed to Solved lynxdabliu • about 1 month ago