# Mailcow / Stalwart

Mail you run, plus a client you already know. Mailcow is GPL-3.0; Stalwart core is AGPL-3.0 — Outlook, Superhuman, Proton Mail, Fastmail, and HEY without the hosted mailbox seat.

**Replaces:** Microsoft Outlook / Superhuman / Proton Mail / Fastmail / HEY

**Tier:** Medium

## Problem

Microsoft Outlook is a hosted mailbox and a desktop client. Superhuman is a premium client on top of Gmail or Outlook. Proton Mail is hosted end-to-end encrypted mail — this stack is IMAP/JMAP you host, not Proton's E2E. Fastmail is hosted IMAP. HEY is a unique inbox (Screen/Feed stays behind). You wanted IMAP/JMAP on hardware you control and a client on the laptop. Mailcow is GPL-3.0 (mailcow/mailcow-dockerized; last push 23 Oct 2026). Stalwart is dual-licensed AGPL-3.0 and SELv2 (stalwartlabs/stalwart; GitHub license field unset; last push 20 Oct 2026) — skip SELv2 if you want OSS-only. Mail-in-a-Box is CC0-1.0 (mail-in-a-box/mailinabox; last push 22 Oct 2026) if you want that one-box installer. Thunderbird is the MPL desktop client (workstation, not a Railway service). SnappyMail is AGPL-3.0 webmail. This is not Outlook's every Copilot SKU, Superhuman's split inbox AI, or HEY's Screen/Feed. Consumer Gmail stays on /replace/gmail (Mailflare / Stalwart). You still need a public IP, MX, and rDNS.

## Stack

- [Mailcow](https://mailcow.email) — GPL-3.0 dockerized mail server — the published Outlook path
- [Stalwart](https://stalw.art) — AGPL-3.0 core IMAP/JMAP/SMTP (skip SELv2)
- [Mail-in-a-Box](https://mailinabox.email/) — CC0-1.0 one-box installer if you want that path

## Estimated SaaS cost saved

| You stop paying | Typical / year | Self-host instead |
|---|---:|---|
| Microsoft Outlook / Superhuman (small team) | $1,200 | Mailcow or Stalwart + Thunderbird |

**About $1,200 / year** on a small team, before you count lock-in.

## Deploy on Railway

Mail wants a public IP, MX, and ports 25/465/587 — a VPS more than a single Railway service. Mailcow is docker-compose. Stalwart is one binary plus a volume. Mail-in-a-Box expects to own the box. Thunderbird stays on the laptop. No one-click template in this repo yet — Start on Railway only if you already know the MX story. Gmail-shaped Workers mail stays on /stacks/stalwart-mail.

[Start on Railway](https://c17.io/go/railway/mailcow-mailbox?from=%2Fstacks%2Fmailcow-mailbox.md)

[Mailflare / Stalwart if this is Gmail on Workers, not Outlook](https://c17.io/stacks/stalwart-mail)

## AGENT_PROMPT

```
Replace Outlook or Superhuman with Mailcow (preferred mailbox) or Stalwart (AGPL core; skip SELv2).

- Public IP, MX, rDNS. Persist mail data. Create one mailbox. Point Thunderbird (desktop) or SnappyMail (webmail) at IMAP/JMAP. Do not claim Outlook Copilot or Superhuman's AI inbox.
- Mail-in-a-Box if you want that installer — /compare/mailcow-vs-mail-in-a-box. Gmail on Workers stays on /stacks/stalwart-mail.
- Write AGENT_PROMPT.md.
```

## FAQ

### Mailcow or Stalwart?

Mailcow if you want the published Outlook path (docker-compose groupware). Stalwart if you want one Rust binary — skip SELv2. /compare/stalwart-vs-mailcow.

### Where does Thunderbird run?

On the laptop. This page is the mailbox. Superhuman is a client; Thunderbird is the client you keep.

### Is this Gmail?

Gmail stays on /replace/gmail (Mailflare / Stalwart). This page is Outlook/Superhuman/Proton Mail/Fastmail/HEY.

### Is this Proton's E2E?

No. Proton Mail is hosted end-to-end encryption. This page is IMAP/JMAP you host. HEY's Screen/Feed stays behind.

### Are these free?

Mailcow is GPL-3.0. Stalwart core is AGPL-3.0 if you skip SELv2. Mail-in-a-Box is CC0-1.0. You pay the VPS and IP reputation.

Source: https://c17.io/stacks/mailcow-mailbox
