MailHog logo

MailHog

  •  0 ratings
In category: Communication / Email / Mail Transfer Agents

About MailHog

Small Golang executable which runs an SMTP MTA gateway that accepts all mail and displays in web interface. Useful for debugging or development.

  •   492  
  •   0  
  •   0  
  •   0  
Github stats:
  •  Commits: N/A  
  •   N/A  
  •   N/A  
  •  Latest commit: N/A  

Deploy this app to Linode with a free $100 credit!

Languages/Platforms/Technologies:
Lincenses:

More about MailHog

MailHog Download GoDoc Build Status

Inspired by MailCatcher, easier to install.

  • Download and run MailHog
  • Configure your outgoing SMTP server
  • View your outgoing email in a web UI
  • Release it to a real mail server

Built with Go - MailHog runs without installation on multiple platforms.

Overview

MailHog is an email testing tool for developers:

  • Configure your application to use MailHog for SMTP delivery
  • View messages in the web UI, or retrieve them with the JSON API
  • Optionally release messages to real SMTP servers for delivery

Installation

Manual installation

Download the latest release for your platform. Then read the deployment guide for deployment options.

MacOS

brew update && brew install mailhog

Then, start MailHog by running mailhog in the command line.

Debian / Ubuntu Go < v1.18

sudo apt-get -y install golang-go
go get github.com/mailhog/MailHog

Go >= v1.17 (Debian Bookworm)

sudo apt-get -y install golang-go
go install github.com/mailhog/MailHog@latest

Then, start MailHog by running /path/to/MailHog in the command line.

E.g. the path to Go's bin files on Ubuntu is ~/go/bin/, so to start the MailHog run:

~/go/bin/MailHog

FreeBSD

pkg install mailhog
sysrc mailhog_enable="YES"
service mailhog start

Docker

Run it from Docker Hub or using the provided Dockerfile

Configuration

Check out how to configure MailHog, or use the default settings: * the SMTP server starts on port 1025 * the HTTP server starts on port 8025 * in-memory message storage

Features

See MailHog libraries for a list of MailHog client libraries.

  • ESMTP server implementing RFC5321
  • Support for SMTP AUTH (RFC4954) and PIPELINING (RFC2920)
  • Web interface to view messages (plain text, HTML or source)
  • Supports RFC2047 encoded headers
  • Real-time updates using EventSource
  • Release messages to real SMTP servers
  • Chaos Monkey for failure testing
  • See Introduction to Jim for more information
  • HTTP API to list, retrieve and delete messages
  • See APIv1 and APIv2 documentation for more information
  • HTTP basic authentication for MailHog UI and API
  • Multipart MIME support
  • Download individual MIME parts
  • In-memory message storage
  • MongoDB and file based storage for message persistence
  • Lightweight and portable
  • No installation required

sendmail

mhsendmail is a sendmail replacement for MailHog.

It redirects mail to MailHog using SMTP.

You can also use MailHog sendmail ... instead of the separate mhsendmail binary.

Alternatively, you can use your native sendmail command by providing -S, for example:

/usr/sbin/sendmail -S mail:1025

For example, in PHP you could add either of these lines to php.ini:

sendmail_path = /usr/local/bin/mhsendmail
sendmail_path = /usr/sbin/sendmail -S mail:1025

Web UI

Screenshot of MailHog web interface

Contributing

MailHog is a rewritten version of MailHog, which was born out of M3MTA.

Clone this repository to $GOPATH/src/github.com/mailhog/MailHog and type make deps.

See the Building MailHog guide.

Requires Go 1.4+ to build.

Run tests using make test or goconvey.

If you make any changes, run go fmt ./... before submitting a pull request.

Licence

Copyright ©‎ 2014 - 2017, Ian Kent (http://iankent.uk)

Released under MIT license, see LICENSE for details.

Comments (0)

Please login to join the discussion on this project.

MailHog Reviews (0)

Overall Rating

None

based on 0 ratings

Please login to review this project.

No reviews for this project yet.

↑ back to top

pCloud Lifetime

Popular Projects

FluxBB

in Social Networks and Forums
 33k    0    0    0  

Nextcloud

in File Transfer & Synchronization
 20k    1    1    0  

Libreddit

in Social Networks and Forums
 7k    0    1    0  

CasaOS

in Self-hosting Solutions
 5k    0    0    0  

Dashboard

in Personal Dashboards
 5k    0    0    0  

Audiobookshelf

in Audio Streaming
 5k    0    1    0  

Mediagoblin

in Photo and Video Galleries
 4k    0    0    0  

Most Discussed

Nextcloud

in File Transfer & Synchronization
 20k    1    1    0  

Tube Archivist

in Automation
 3k    0    1    0  

OneDev

in Project Management
 2k    0    0    0  

iodine

in Proxy
 2k    0    0    0  

Alf.io

in Booking and Scheduling
 2k    0    0    0  

sysPass

in Password Managers
 1k    0    0    0  

Misskey

in Social Networks and Forums
 2k    0    0    0  
Linux VPS from $11/yr.
RackNerd VPS for $11.38/mo

Top Rated Projects

Gitea

 1 rating
in Project Management

Bagisto

 1 rating
in E-commerce

LinkAce

 1 rating
in Bookmarks and Link Sharing

Pydio

 1 rating
in File Transfer & Synchronization

Audiobookshelf

 1 rating
in Audio Streaming

Nextcloud

 1 rating
in File Transfer & Synchronization

Seafile

 1 rating
in File Transfer & Synchronization

Categories

You May Also Be Interested In

Slimta logo
Slimta cover

Slimta

Mail Transfer Library built on Python.

vSMTP logo
vSMTP cover

vSMTP

Next-gen MTA. Secured, Faster and Greener.

Maildrop logo
Maildrop cover

Maildrop

Disposable email SMTP server, also useful for development.