Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Nodemailer and Gmail after May 30 2022

enter image description here

Sending an email using NodeMailer & Gmail

Google has reported that after May 30 third party apps cannot use username and password for signing in. Does this affect nodemailer. We usually allow less secure APP in the gsuit gmail setting before using it in nodemailer.

    var transporter = nodemailer.createTransport({
        service: 'gmail',
        auth: {
         user: '[email protected]',
         pass: 'yourpassword'
        }
     });
like image 618
UJ India Avatar asked Sep 12 '25 04:09

UJ India


2 Answers

It would help if you generated an app password to use nodemailer.

  1. First, you need to turn on two-factor-authentication.
  2. And then in your manage account go to security.
  3. You can see the app password below two-step verification.
  4. Go to app password select app other and write custom app name (example project name) and click on generate.
  5. You get a password use that password instead of your mail password.
like image 133
Vipul Ram Avatar answered Sep 14 '25 17:09

Vipul Ram


I've been digging all over for this. Their docs are pretty woeful about the change. Found this, not definitive...I'm in the "set up app password let's see if it still works" camp.

Note the reply "Second, yes, the best information we have is that App Passwords will continue to work."

https://support.google.com/mail/thread/157808790/will-imap-work-after-may-30th?hl=en

like image 34
Tim C Avatar answered Sep 14 '25 19:09

Tim C