Project

General

Profile

Email notification issue

Added by am2jr jr 4 months ago

i'm using smtp.gmail.com as my SMTP server, but it is not working. when i try to click test email button in admin notification tab
it always showing the error "An error occurred while sending mail (535-5.7.8 Username and Password not accepted. For more information, go to )"
this is my configuration in yml.

email_delivery:
delivery_method: :smtp
smtp_settings:
enable_starttls_auto: true
address: "smtp.gmail.com"
port: 587
domain: "smtp.gmail.com"
authentication: :plain
user_name: ""
password: "myPassword"

please help, my email username and passowrd.. i have double confirm, its the correct one because its my personal email


Replies (2)

RE: Email notification issue - Added by Diana Peters 3 months ago

To fix the "Username and Password not accepted" error with smtp.gmail.com, enable two-step verification for your Google account and generate an app-specific password. Use this app-specific password in your yml configuration. Also, ensure "Less Secure Apps" is enabled in your Google account settings if needed

RE: Email notification issue - Added by Sak Ono 25 days ago

Thanks for sharing your configuration details. The error "535-5.7.8 Username and Password not accepted" often occurs due to recent security updates from Google. Here are a few steps to resolve this issue:

1. Enable Two-Step Verification: Go to your Google Account settings and enable two-step verification. This is required to generate app-specific passwords.
2. Generate an App-Specific Password: After enabling two-step verification, go to the "App passwords" section in your Google Account settings and generate a 16-digit app-specific password. Use this password instead of your regular Gmail password in your SMTP settings
3. Update SMTP Settings: Replace your regular password with the app-specific password in your configuration. Here's an updated example:

email_delivery:
  delivery_method: :smtp
  smtp_settings:
    enable_starttls_auto: true
    address: "smtp.gmail.com" 
    port: 587
    domain: "smtp.gmail.com" 
    authentication: :plain
    user_name: "myEmail@gmail.com" 
    password: "your-app-specific-password" 

4. Check Less Secure Apps: Ensure that "Less secure app access" is turned off in your Google Account settings. Google has deprecated this option, but it's good to double-check.

    (1-2/2)