DEV Community 👩‍💻👨‍💻

Discussion on: Submit a form and receive email Using Express, Nodejs, Nodemailer and MailGun - Complete Guide

umekalu profile image
Ume Abraham Kalu Author

The big deal here is SMTP protocol and Mailgun API.

Nodemailer provides a standard interface for sending both text and HTML-based emails.

Based on the mailgun-js module and the nodemailer module, the Mailgun Transport was born. This is a transport layer, meaning it will allow you to send emails using nodemailer, using the Mailgun API instead of the SMTP protocol!

Nodemailer allows you to write code once and then swap out the transport so you can use different accounts on different providers. On top of that, it's a super solid way of sending emails quickly on your node app(s).

The Mailgun transport for nodemailer is great to use when SMTP is blocked on your server or you just prefer the reliability of the web api!