# MailCatcher

> Catches mail and serves it through a dream

Source: https://talira.ai/catalog/mailcatcher-p3k1rf3v
Every listing: https://talira.ai/catalog.md

- Kind: Open source
- Types: Infrastructure, Web app, Command-line tool
- Categories: [developer tools / testing / email sandbox](https://talira.ai/categories/developer-tools/testing/email-sandbox)
- Platforms: linux, macos, docker[^2]
- Licence: MIT[^3][^4]
- Pricing: Free and open source[^3]
- Free tier: yes[^3]
- Self-hostable: yes[^2]
- API: yes[^2]
- Creator: Samuel Cochran (sj26)

MailCatcher is a Ruby gem that runs a simple SMTP server on port 1025 which catches every message sent to it and shows it in a web interface on port 1080: HTML, plain text and source views, attachments, and messages that appear instantly over WebSockets. A `catchmail` command stands in for sendmail for PHP, and a JSON API (`/messages` and each message's parts) lets tests fetch what was sent. Samuel Cochran has maintained it since 2010; it's MIT licensed, installed with `gem install mailcatcher` (not in an app's Gemfile) or run from its [Docker](https://talira.ai/catalog/docker-engine-9442r3nw.md) image. The README says it's a development tool, not a mail service.

## Links

- Website: https://mailcatcher.me/
- GitHub: https://github.com/sj26/mailcatcher

## Ways to install

### Package managers

- [Homebrew](https://talira.ai/catalog/homebrew-djy17yn9.md): <https://formulae.brew.sh/formula/mailcatcher>[^1]

## Problems it solves

- catch every email our Rails app sends in development so none go to real people
- look at the signup email's HTML in a browser while developing, without a real inbox
- a fake SMTP server for local development of a PHP app that uses mail()
- download the raw email our app sent to check its headers and attachments
- fetch sent emails as JSON in an integration test
- a local mail catcher for Django development

## Features

- SMTP server that catches all mail (default port 1025)
- web interface (default port 1080) with HTML, plain text and source views
- attachments listed and downloadable; original message downloadable
- new mail shown instantly over WebSockets
- catchmail sendmail replacement for PHP
- JSON API: /messages and each message's HTML, plain text, parts and source
- options for SMTP and HTTP addresses and ports, message limit and HTTP path prefix
- runs as a background daemon or in the foreground
- keyboard navigation between messages
- Docker image sj26/mailcatcher

## Limitations

- Doesn't fully support UTF-8 sent raw over SMTP: the mail library must encode messages[^2]

## Capabilities

- Has an API: plan not known
- Has a command line tool: plan not known

## Trust

Overall: 0.34 out of 1.
Signals: backing 0.20, extensibility 0.40.

- created by Samuel Cochran (sj26)

Warnings:

- GitHub activity not fetched yet

## Alternatives

- [Mailpit](https://talira.ai/catalog/mailpit-qq9rm9v9.md): An email and SMTP testing tool with API for developers
- [Mailtrap](https://talira.ai/catalog/mailtrap-j34knxxh.md): We Send Emails
- [MailHog](https://talira.ai/catalog/mailhog-kgepk824.md): Web and API based SMTP testing

## Sources

[^1]: https://formulae.brew.sh/api/formula.json (checked 21 Nov 2026)
[^2]: https://github.com/sj26/mailcatcher (checked 20 Nov 2026)
[^3]: https://github.com/sj26/mailcatcher/blob/main/LICENSE (checked 20 Nov 2026)
[^4]: https://rubygems.org/gems/mailcatcher (checked 20 Nov 2026)
