| Forum

How to configure AWS SES in OJS for email notification?

I am hosting OJS v3.3.0-5 and would like to use AWS SES (Simple Email Service) for email notification. I have tried setting it up by configuring, but it seems to be not working. Can you please check if there is anything wrong with my configuration?


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

; SMTP server settings
smtp_server =
smtp_port = 25

; Enable SMTP authentication
; Supported smtp_auth: ssl, tls (see PHPMailer SMTPSecure)
; smtp_auth = ssl
smtp_username = <MY_AWS_SES_USERNAME>
smtp_password = <MY_AWS_SES_PASSWORD>
; Supported smtp_authtype: RAM-MD5, LOGIN, PLAIN, XOAUTH2 (see PHPMailer AuthType)
; (Leave blank to try them in that order)
; smtp_authtype =

Can you try to install sendmail?

In Ubuntu,

sudo apt-get install sendmail


sudo yum install sendmail

I have installed sendmail, but still I am not able to get the email working. I am seeing the below message in my error.log file after enabling smtp in

[php7:notice] [pid 3432] [client] Connection: opening to, timeout=300, options=array(), referer:

You need to enable smtp=On by removing the ; from the line.

smtp = On

Thanks, Asha for the reply. I uncommented smtp = On, but still I am not receiving any emails. I am seeing the following error in /var/log/apache/error.log

sh: 1: /usr/sbin/sendmail: not found
[Tue Apr 20 17:23:40.481463 2021] [php7:notice] [pid 1161] [client] Could not instantiate mail function., referer:

Do I have to enable/verify anything at AWS level?

The correct configuration is

; Email Settings ;


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

; SMTP server settings
smtp_server =
smtp_port = 465

; Enable SMTP authentication
; Supported mechanisms: ssl, tls
smtp_auth = ssl
smtp_username = <YOUR_AWS_SMTP_USERNAME>
smtp_password = <YOUR_AWS_SMTP_PASSWORD>

; Enable suppressing verification of SMTP certificate in PHPMailer
; Note: this is not recommended per PHPMailer documentation
; smtp_suppress_cert_check = On

; Allow envelope sender to be specified
; (may not be possible with some server configurations)
allow_envelope_sender = On

; Default envelope sender to use if none is specified elsewhere
default_envelope_sender = <YOUR_FROM_EMAIL_ADDRESS>

; Force the default envelope sender (if present)
; This is useful if setting up a site-wide no-reply address
; The reply-to field will be set with the reply-to or from address.
force_default_envelope_sender = On

To get the SMTP credentials, login to AWS Management Console and navigate to SES (Simple Email Service) service.