I\'m trying to send the email gmail smtp but I\'m getting the error:
My email and password is correct I\'m using the nodemailer for sending the mail;
var transporter = nodemailer.createTransport({
service: 'Gmail',
auth: {
user: 'user@gmail.com',
pass: 'password'
}
});
Try the above, and do the following which worked for me.
Login to https://www.google.com/settings/security/lesssecureapps and TURN ON Access for less secure apps.
I hope it will work for you too.
Thank you.
var transporter = nodemailer.createTransport({
service: 'Gmail',
auth: {
user: 'user@gmail.com',
pass: 'password'
}
});
Try this.