Can’t send email using email function in google cloud platform

emailemail-serverg-suitegoogle-cloud-platformgoogle-compute-engine

We have G Suite account with our domain name. And our server is Google cloud platform. we are using PHP for our development, we trying different code for sending mails, but cant receive any mails using mail functions, and we contact G suite account they said all the settings are working perfectly…this issue is regarding the google cloud platform, cloud reject the mails.

Is any additional settings needed to implement the google cloud platform to establish a connection with G suite account?

Should we have an AppEngine account for sending emails via code?

Any ideas on what might be happening here or what to test next?

Thanks in Advance…

Best Answer

Google Compute Engine does not allow outbound connection on ports 25, 465 and 587. Moreover port 25 is also blocked for SMTP relay through G Suite as mentioned here:

Note: Port 25 is always blocked and cannot be used, even through SMTP relay using Google Apps.

As a workaround, you can use trusted third party providers such as SendGrid, Mailgun, or Mailjet to setup mail function on GCE or use port 465, 587 for STMP relay using G suite on GCE instance. You can find more information and steps on this link.

Related Topic