[email] Gmail smtp configuration for Drupal 7


1 Answers

Step 1: Download SMTP module and enable it.

Step 2: Go to Admin > Configuration > System > SMTP authentication support and set the following values:

  • Turn this module on or off: On.
  • SMTP server settings:
    • smtp server: smtp.gmail.com
    • smtp backup server: leave blank.
    • smtp port: 465
    • use encrypted protocol: select "use SSL"
  • SMTP authentication:
    • Enter a valid Gmail email address and password.
  • Email options:
    • Set the same email address that you used at SMTP Authentication.
  • Send test email: set an email to receive a sample email and to test whether the module is working.
  • Enable debugging: yes.

Step 2a(Optional): Allow Less Secure Apps Access which is here: http://www.google.com/settings/security/lesssecureapps

Step 3: Click on Save and go to your inbox to check. If there is an testing email then it is fine.

Note: Your email address provided in your smpt setting MUST be the same like in your site information.

Question

I want to send email in Drupal 7. So, does anyone know how to configure Gmail SMTP on Drupal 7?




For me, just following the steps in Juampy's answer didn't work. The error "Unable to send mail. Contact site administrator." continued to display. Do the following first and then configure SMTP module as per his answer.

Before installing SMTP module, download PHPMailer and extract it. Rename the folder as 'phpmailer' and copy the folder into module folder of SMTP module. Then, install the SMTP module.

An alternative configuration is as follows:

  • smtp port: 587

  • use encrypted protocol: select "use TLS"




Related