Gmail SMTP setup 2023

I’m sorry if this has been asked too many times - I’m new and trying to get SuiteCRM to work.

I am unable to configure Gmail with SMTP. With the correct SMTP port over TLS, I get this error:

An email error occurred:SMTP Error: Could not connect to SMTP host. Failed to connect to serverSMTP server error: Failed to connect to server SMTP code: 111 Additional SMTP info: Connection refused

Is there a way to make this work?

Alternatively, can I use PHP mail instead of SMTP so the mails go from the server itself? I don’t need to use email to communicate via SuiteCRM. I just need task, meeting and calendar reminders to be sent by the system to users.

Hi… Check your Gmail account security. I know that Gmail have some security when you want to connect with another aplication

I’ve checked and turned off 2-Step Verification. I don’t see any other security settings thatI can reduce.

I get this error:

3: Connection: opening to, timeout=300, options=array()
3: Connection failed. Error #2: stream_socket_client(): Unable to connect to (Connection refused) [/home/public_html/suitecrm/vendor/phpmailer/phpmailer/src/SMTP.php line 397]
1: SMTP ERROR: Failed to connect to server: Connection refused (111)
3: SMTP Error: Could not connect to SMTP host. Failed to connect to server

No difference if i change from TLS or SSL and port 587. I also tried to enable 2 step verification and setup App Password. Not sure why, but it doesn’t work.

I’m wondering how most people use SuiteCRM without email functionality working, pls do suggest.

I too am getting the “An email error occurred:SMTP connect() failed.” This previously worked for me. But my GoDaddy database became corrupted. I have used the Google Gmail one-time password generation. Nothing works. I have tried multiple combinations of other SMTP email relays. Nothing works.

Getting frustrated.

If i change ‘smtp’ to ‘Sendmail’ in suitecrm/public/legacy/modules/Emails/Email.php line 820, I can send a test mail out from the Email Settings page. While should mean email sending is working - but I still don’t get reminder notification emails or emails that are composed by users.

If i use a non-gmail server based SMTP, it works. I can test email sending, I can compose and send mails but reminder emails don’t work.

I can’t go live with my installation, despite having sent hours implementing and configuring it :unamused:

  1. Sign in to your Gmail account.
  2. Go to the Google Account Security page by visiting the following link:
  3. Scroll down to the “Less secure app access” section and click on the “Turn on access (not recommended)” link. Please note that the wording may vary slightly, but the link should be available.
  4. On the next screen, toggle the switch to enable “Allow less secure apps.” You may need to verify your account with your password or other security measures.
  5. Once enabled, you should be able to use less secure apps with your Gmail account.

There is no option called “Less secure app access” anymore.