Terminal Email

mblaze

CLIEmail client

Set of small Unix utilities for reading, searching, threading and composing mail stored in Maildir folders.

mblaze is a collection of commands such as mlist, mscan, mshow, mthread, mpick and mcom that are combined in shell pipes. It works directly on Maildir folders with no database or cache, and can import and export mbox files; its design is inspired by MH but written from scratch. It has no networking of its own: a sync tool such as mbsync fetches mail and a sendmail-compatible program such as msmtp sends it. It suits users who want to script mail handling with standard Unix tools.

Type
Email client
Interface
Command-line tools and prompts
Systems
Runs on Linux, macOS and BSD, on Windows through WSL. Not available for Android.
Language
C
License
CC0 1.0 and MIT
Latest version
1.4
Background
Inspired by MH; written from scratch
Maintained
Yes
Website
github.com
Source
github.com/leahneukirchen/mblaze
Documentation
github.com

Install

SystemSupportInstall
LinuxNative
aptsudo apt install mblaze
xbpssudo xbps-install mblaze
AURyay -S mblaze
macOSNative
Nixnix profile install nixpkgs#mblaze

No Homebrew formula; available through Nix or by building from source with GNU make.

WindowsThrough WSL
WSLsudo apt install mblaze

No native build; upstream lists Cygwin as tested, and the Debian package works in WSL.

BSDNative
FreeBSD pkgpkg install mblaze
OpenBSDpkg_add mblaze
AndroidNot supported

No Termux package.

Protocols and features

Protocols
Protocolmblaze
IMAPThrough a separate tool
POP3Through a separate tool
SMTPThrough a separate tool
JMAPNo
MaildirYes
mboxNo
notmuchNo
Features
Featuremblaze
OpenPGPvia contrib scripts
S/MIMENo
OAuth2 sign-inNo
ThreadsYes
Searchmpick and magrep filter messages by headers, flags and content
HTML mailvia a filter command in ~/.mblaze/filter used by mshow
MouseNo
Multiple accountsvia separate Maildirs and profile settings
Offline usefull; works only on local Maildir
CalendarNo
ContactsNo
Vim-style keysNo
Configuration~/.mblaze/profile (header-style key: value lines)

Pros and cons

Pros

  • Each command does one job, so mail handling is easy to combine in pipes and scripts.
  • Works directly on Maildir with no index or database to maintain.
  • Small C programs with no external library dependencies.

Cons

  • No built-in IMAP, POP3 or SMTP; needs mbsync and msmtp or similar tools.
  • Command-line only, with no full-screen interface.
  • OpenPGP and S/MIME handling relies on unsupported contrib scripts.

Use mblaze with Forward Email

A working setup for a Forward Email mailbox. Replace you@example.com with your alias and the password command with your own. The same settings work with any provider once the server names change.

~/.mbsyncrc, ~/.config/msmtp/config and ~/.mblaze/profile
# 1) ~/.mbsyncrc: sync to ~/Mail/forwardemail (isync 1.5+ syntax)
IMAPAccount forwardemail
Host imap.forwardemail.net
Port 993
User you@example.com
PassCmd "pass show email/forwardemail"
TLSType IMAPS

IMAPStore forwardemail-remote
Account forwardemail

MaildirStore forwardemail-local
SubFolders Verbatim
Path ~/Mail/forwardemail/
Inbox ~/Mail/forwardemail/INBOX

Channel forwardemail
Far :forwardemail-remote:
Near :forwardemail-local:
Patterns *
Create Both
SyncState *

# 2) ~/.config/msmtp/config (chmod 600)
account forwardemail
host smtp.forwardemail.net
port 465
tls on
tls_starttls off
auth on
user you@example.com
passwordeval "pass show email/forwardemail"
from you@example.com
account default : forwardemail

# 3) ~/.mblaze/profile
Local-Mailbox: Your Name <you@example.com>
Maildir: ~/Mail/forwardemail
Outbox: ~/Mail/forwardemail/Sent Mail
Sendmail: msmtp

# Usage: mbsync forwardemail; mlist ~/Mail/forwardemail/INBOX | mthread | mscan
ProtocolServerPortSecurity
IMAPimap.forwardemail.net993SSL/TLS
POP3pop3.forwardemail.net995SSL/TLS
SMTPsmtp.forwardemail.net465SSL/TLS
SMTPsmtp.forwardemail.net587STARTTLS

Username: your full alias address, such as you@example.com. Password: the one shown by Generate Password next to the alias in your Forward Email account. Folders: INBOX, Drafts, Sent Mail, Trash, Spam and Archive.

Prefer no config at all? Forward Email's terminal app signs in with your account and has mail, calendar and contacts in one program.

Compare mblaze

All mblaze alternatives

Questions

Does mblaze work on Windows?

Not natively. It runs in Windows Subsystem for Linux (WSL). No native build; upstream lists Cygwin as tested, and the Debian package works in WSL.

Does mblaze support IMAP?

Through a separate tool. mblaze reads local mail, so a sync program such as isync copies it from the IMAP server.

Is mblaze open source?

Yes, under the CC0 1.0 and MIT.

How do I use mblaze with Forward Email?

Use the config in the Forward Email section on this page, saved as ~/.mbsyncrc, ~/.config/msmtp/config and ~/.mblaze/profile, and replace the address and password with your own.

Sources