MailCatcher runs a simple SMTP server that collects outbound mail and shows it in a browser UI. Point development apps at its SMTP port instead of a real mail relay.
Overview
MailCatcher is a development tool that runs a lightweight SMTP server and a companion web interface. Any message your application sends to the catcher is stored for inspection instead of being delivered to the public internet.
The web UI shows HTML, plain text, and source views where applicable, rewrites HTML so inline assets display safely, and lists attachments for separate download. You can download the original message for viewing in a desktop mail client. Command-line flags adjust the SMTP and HTTP bind addresses and ports, and incoming mail can refresh instantly over WebSockets or on a periodic poll.
Typical setup is installing the Ruby gem and running the mailcatcher command, then configuring frameworks such as Rails, Django, or PHP mail settings to deliver to localhost on the default SMTP port. A catchmail helper acts like sendmail for PHP integration. A Docker image is published for containerized use.
A small JSON HTTP API exposes message lists and individual parts for automation. The author states MailCatcher is for development only, not as a public mail service, and notes limits around encoding and basic processing.
Key features
- Local SMTP listener for dev apps
- Web UI for captured messages
- HTML, plain text, and source views
- Attachment listing and downloads
- Configurable SMTP and HTTP ports
- WebSocket or timed inbox updates
- REST JSON message API
- catchmail sendmail-style helper
Use cases
- Previewing app registration emails locally
- Rails or Django development mail testing
- PHP sendmail path testing with catchmail
- Inspecting HTML templates before production SMTP
- CI or Dockerized dev stacks needing fake mail