Google Workspace Email SMTP
vking45
HOBBYOP

10 months ago

When I am using my personal Gmail username and password for SMTP configuration and sending emails from my Railway deployed Go Server, it works perfectly, but when I am using my Google Workspace Email for the same purpose, it fails, I have been stuck at this for about 3 days now, I have checked all the available resources on Google Workspace side, I am not using Gmail Relay, the password being used is an App Password with Less Secure Apps turned ON.

I want to understand if there any restrictions on Railway's side ? If somebody has already implemented this, can you please guide me !

Solved

21 Replies

10 months ago

We have disabled SMTP for free, trial, and hobby, SMTP is only enabled for the pro plan and above.


morphdev
HOBBY

10 months ago

@Brody Hi, i'm trying to use this when deploying on railway instead, which I think uses API rather than SMTP? Can you confirm whether I should expect this to work or not?

https://github.com/krig/strapi-provider-email-brevo-k


10 months ago

That uses an HTTPS API to send emails so that will work perfectly!


morphdev
HOBBY

10 months ago

@Brody connection seems to be timing out when trying to send emails from railway but not when running locally. Any idea what could be causing this?


10 months ago

Please provide error logs.


morphdev
HOBBY

10 months ago


data:
{ }
code:
"ETIMEDOUT"
command:
"CONN"
level:
"error"
timestamp:
"2025-08-27T14:41:05.280Z"```


10 months ago

I'm going to need more information. What is the host and port that the connection is timing out with?


morphdev
HOBBY

10 months ago

Not providing a host and port for the email, just a API key to Brevo. The timeout is when sending an email using the linked package


10 months ago

Please provide the host and port that the connection is timing out with.


morphdev
HOBBY

10 months ago

I'm not sure what you mean. The package doesn't require a host and port providing.

Is there a range of IP addresses I might need to permit in Brevo to allow requests from Railway?


10 months ago

Does Brevo have a whitelist?


morphdev
HOBBY

10 months ago

ive just deactivated ip blocking and its still timing out. Let me have a look in the CMS for any other reasons


techgosafeagency
PRO

10 months ago

I'm facing similar situation, have an account from google workspace and app password, sending emails using nodemailer, suddenly I stop being able to do this, any recommended alternative to this? Why was blocked?


hiringmine-portal
PRO

10 months ago

facing same issue


hiringmine-portal

facing same issue

techgosafeagency
PRO

10 months ago

even when you are PRO??? Or just upgrade your plan?


decine84
HOBBY

10 months ago

Subject: Nodemailer Connection Timeout on Railway

Hi Railway team,

My app is trying to send emails using Nodemailer with Gmail SMTP.

It works on localhost, but in production on Railway I get ETIMEDOUT errors when connecting to smtp.gmail.com:465 or 587.

Can you confirm if outbound SMTP ports are blocked on Railway?

If so, is there any way to allow SMTP connections for my project,

or must I switch to a provider like SendGrid / Postmark?


decine84

Subject: Nodemailer Connection Timeout on Railway Hi Railway team, My app is trying to send emails using Nodemailer with Gmail SMTP. It works on [localhost](http://localhost), but in production on Railway I get ETIMEDOUT errors when connecting to [smtp.gmail.com:465](http://smtp.gmail.com:465) or 587\. Can you confirm if outbound SMTP ports are blocked on Railway? If so, is there any way to allow SMTP connections for my project, or must I switch to a provider like SendGrid / Postmark?

andremaytorena
PRO

10 months ago

https://discord.com/channels/713503345364697088/1408466368420118528

this is what I was told, I just switched over to the gmail api, its pretty much free


andremaytorena

<https://discord.com/channels/713503345364697088/1408466368420118528> this is what I was told, I just switched over to the gmail api, its pretty much free

decine84
HOBBY

10 months ago

I could not access it


decine84

I could not access it

andremaytorena
PRO

10 months ago

"We block outbound SMTP."


andremaytorena

"We block outbound SMTP."

decine84
HOBBY

10 months ago

so what is the propose solution to it. I had to use email service on my app


decine84

so what is the propose solution to it. I had to use email service on my app

andremaytorena
PRO

10 months ago

gmail has an api, I use that now


Status changed to Solved brody 10 months ago


Welcome!

Sign in to your Railway account to join the conversation.

Loading...