2

I'm using magento 2.3.1, every time I edited or add users or roles I get this error.

5.7.8 Username and Password not accepted. Learn more at 5.7.8 https://support.google.com/mail/?p=BadCredentials l17sm2797996wrq.37 - gsmtp

Email is working fine, I configured it with Google SMTP. Not sure what is the cause of that error. The user is added or edited correctly, I just see the error but no real impact, everything works.

3 Answers 3

0

Your error pointed that bad credentials using gmail smtp. See this url : https://support.google.com/mail/thread/5621336?hl=en

Did you tried send test email ? First try to send test email from admin side. Check that any test email or transaction emails are working or not.

Also test your server log. You can find log at var/log folder of your magento directory.

5

Fix the SMTP Gmail error to allow access to Allow less secure apps in gmail.

Go to https://myaccount.google.com/lesssecureapps

Allow less secure apps: ON

Refer the attach screenshot.

enter image description here

Hope it help.

2
  • Thanks, perfect and clean answer...!!! Apr 28, 2022 at 16:29
  • To help keep your account secure, from May 30, 2022, ​​Google no longer supports the use of third-party apps or devices which ask you to sign in to your Google Account using only your username and password. Nov 23, 2022 at 9:14
1

Kirti Nariya answer will not work now.

"To help keep your account secure, from May 30, 2022, ​​Google no longer supports the use of third-party apps or devices which ask you to sign in to your Google Account using only your username and password."

So you need to use an application password instead of your Gmail account password.

Authentication: set to Login

Username: set to the username name of the Gmail account that you want to be in charge of sending all the emails within your store

Password: enter your app’s password

You’ll want to create an app password here and use the generated app password for your SMTP configuration.

Read more here -> Configure SMTP Settings for Sending Emails in Magento

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.