Overview
Discover what makes Mox powerful
Mox is a **full‑stack, self‑hosted email platform** written entirely in Go. From the server side it implements **SMTP, IMAP4, Webmail, and a REST‑style HTTP API** for transactional mail. The application is designed to run as a single binary on a dedicated VM or container, with no external dependencies beyond the operating system and DNS resolver. Its core is a high‑performance mail transport that supports **SPF, DKIM, DMARC, DANE, MTA‑STS**, and automatic ACME/TLS provisioning, making it suitable for production deployments that require end‑to‑end encryption and strict authentication.
Language & Runtime
Mail Transport
Storage
Web Interface & API
Overview
Mox is a full‑stack, self‑hosted email platform written entirely in Go. From the server side it implements SMTP, IMAP4, Webmail, and a REST‑style HTTP API for transactional mail. The application is designed to run as a single binary on a dedicated VM or container, with no external dependencies beyond the operating system and DNS resolver. Its core is a high‑performance mail transport that supports SPF, DKIM, DMARC, DANE, MTA‑STS, and automatic ACME/TLS provisioning, making it suitable for production deployments that require end‑to‑end encryption and strict authentication.
Architecture & Technical Stack
- Language & Runtime: Go 1.22+; the entire codebase follows RFC‑centric design, with extensive automated tests and fuzzing.
- Mail Transport: A custom SMTP/IMAP implementation that handles extensions (STARTTLS, AUTH mechanisms) and implements reputation‑based throttling and Bayesian spam filtering per user.
- Storage: A lightweight, file‑system‑based mailbox format (similar to Maildir) stored under each user’s home directory; configuration and state are kept in plain text YAML files for transparency.
- Web Interface & API: A single integrated web server (port 443) that serves static assets, reverse‑proxy capabilities for hosting websites, and a JSON/HTTP API (
/api/v1/...) for sending mail, retrieving events, and webhook integration. - Metrics & Logging: Prometheus metrics are exposed on
/metrics, and structured logs (JSON) can be shipped to any log aggregator.
Core Capabilities for Developers
- Programmable API: Endpoints to send transactional mail, fetch delivery reports, and receive incoming messages via webhooks.
- Extensible Reputation Engine: Developers can hook into the per‑user reputation system to inject custom scoring logic or external blacklists.
- Pluggable Filters: The spam filtering pipeline is modular; custom filters can be added as Go packages and reused across projects.
- Account Autodiscovery: SRV, Microsoft‑style, Thunderbird‑style, and Apple device profiles are auto‑generated, simplifying client configuration.
Deployment & Infrastructure
Mox is container‑ready; a Dockerfile and OCI image are available, making it trivial to spin up in Kubernetes or any container runtime. The binary requires only a user account (mox) and a home directory; it creates its own configuration during the quickstart phase. For high availability, multiple instances can be run behind a load balancer with shared storage (e.g., NFS) for mailboxes, or each instance can serve a distinct domain. The built‑in ACME client means TLS certificates are renewed automatically, eliminating operational overhead.
Integration & Extensibility
The application exposes a webhooks system that can forward delivery status and inbound message events to external services. Its modular design means the core mail processing logic can be imported into other Go projects; many of its non‑server packages are intentionally reusable. The configuration API and web UI allow runtime changes without restarting, which is invaluable for rapid iteration in development environments.
Developer Experience
- Zero External Dependencies: No need to install Postfix, Dovecot, or other mail daemons; everything is bundled.
- Clear Documentation: The source includes RFC‑referenced comments and a comprehensive README; the website hosts a detailed feature list and roadmap.
- Active Community: MIT licensing encourages contribution, and the project’s GitHub repository is actively maintained with frequent releases.
- Testing: Extensive unit, integration, and fuzz tests provide confidence that changes do not regress core protocols.
Use Cases
- Private SaaS Email Service – A startup can deploy Mox to provide secure, self‑hosted email for its users, leveraging the API for transactional mail while keeping full control over data.
- Enterprise In‑House Mail Server – Organizations that require strict compliance can run Mox on their own infrastructure, benefiting from built‑in DMARC and DANE support.
- Developer Sandbox – The
mox localservesubcommand allows developers to test email flows locally without hitting external SMTP providers. - Hybrid Cloud – Mox can act as an edge server that forwards mail to a cloud provider, combining local control with external deliverability.
Advantages Over Alternatives
- Performance & Simplicity: A single Go binary eliminates the overhead of multiple daemons; the code is lean and well‑tested.
- Security by Design: Automatic TLS, strict authentication checks, and reputation‑based throttling reduce the attack surface.
- Licensing & Freedom: MIT license permits commercial use without copyleft constraints, unlike some open‑source mail servers.
- Developer‑Friendly Extensibility: Reusable Go packages and a programmable API make it easier to integrate Mox into existing tooling compared to more monolithic solutions.
Mox thus offers developers a complete, secure, and highly extensible email stack that can be deployed with minimal operational burden while still exposing powerful hooks for customization and automation.
Open SourceReady to get started?
Join the community and start self-hosting Mox today
Related Apps in apis-services
Mastodon
Decentralized, real‑time social networking
Discourse
Open‑source community forum platform with real‑time chat and AI
Rocket.Chat
Secure, open‑source team communication platform
Novu
Unified notification platform for multi‑channel delivery
Mattermost
Secure, self‑hosted team collaboration with chat, voice, and AI
Jitsi Meet
Free, encrypted video conferencing for everyone
Weekly Views
Repository Health
Information
Explore More Apps
Tasks.md
Markdown‑based task board for self‑hosted teams
SAMA
Fast, modern chat server with a custom messaging protocol
Christmas Community
Family gift list to avoid double‑gifting
Otter Wiki
Minimalist Markdown Wiki Powered by Git
SeedDMS
Secure Document Management with Workflow & Notifications
Litlyx
Privacy‑first web analytics without cookies