Sending emails with a Gmail account


I had to move to Gmail. Before that, I was using a quite old-fashioned mail-in-a-box instance.

I have this in /var/www/html/

; Use SMTP for sending mail instead of mail()
smtp = On

; SMTP server settings
smtp_server =
smtp_port = 587

; Enable SMTP authentication
; Supported smtp_auth: ssl, tls (see PHPMailer SMTPSecure)
smtp_auth = ssl
smtp_username =
smtp_password = REDACTED

; Supported smtp_authtype: RAM-MD5, LOGIN, PLAIN, XOAUTH2 (see PHPMailer AuthType)
; (Leave blank to try them in that order)
; smtp_authtype = PLAIN

I also have IMAP activated in Gmail settings.

What I am missing here?

Hi @pachadotdev,

Can you please note what version you’re using (e.g. 3.3.0-8) - in the future, please include this in your posts. Also, have you tried it with this configuration already and are you running into any issues with sending mail?

PKP Team

Thanks. I use OJS
The problem appeared after switching to gmail. Same email account, different provider.

Hi @pachadotdev,

Thanks for clarifying. I’ll see if some of our systems/dev staff can assist when they are available.

Best regards,

PKP Team

1 Like

The information here may be helpful to you:

OJS Gmail SMTP Settings – Two-factor authentication


This topic was automatically closed after 10 days. New replies are no longer allowed.