MailDev receives mail your application sends to a local SMTP port and shows it in a web UI. It helps developers inspect HTML, attachments, and headers without delivering real email.
Overview
MailDev is a Node.js tool that combines an SMTP listener with a browser inbox for development and automated tests. Point your app at the default SMTP and web ports to capture outgoing messages locally instead of sending them to real recipients.
The React interface shows HTML and plain-text bodies, headers, attachments, and resizable responsive previews. WebSocket updates stream new messages, and a REST API lists, searches, downloads, and deletes captured mail.
Optional outgoing SMTP settings let you relay individual messages or use auto-relay rules to forward copies upstream. Version 3 adds TypeScript throughout, configuration files, and an MCP endpoint so agents can search the dev inbox or extract verification links.
Run it via npx, global npm install, Docker Hub image maildev/maildev, or embed it in Node tests using the documented API.
Key features
- SMTP server that catches outbound dev mail
- Web UI with HTML, text, and header views
- REST API and WebSocket inbox updates
- Attachment viewing and responsive preview pane
- Optional upstream SMTP relay and auto-relay rules
- MCP integration for agent-driven inbox queries
Use cases
- Test registration and reset emails locally
- Let QA scripts assert mail content via the API
- Have coding agents read verification links from MailDev