logo
Mail Forwarding (Self-Host)Get Started
Mail Forwarding (Self-Host)

Get Started (Self-Hosting)

Introduction to self-hosting the complete mail forwarding stack. Host and manage the service on your own infrastructure.

This is a guide for self-hosting. If you just want to use the service as an end user, see the User guide instead.

What is Self-Hosting?

Self-hosting is the practice of hosting and managing your own services on infrastructure under your control — such as a VPS, dedicated server, or home server — rather than relying on third-party platforms.

This gives you:

  • Greater autonomy and privacy
  • Full data control
  • Complete customization
  • Responsibility for maintenance, updates, and availability

Stack Overview

The complete mail forwarding stack consists of these components, deployed in this order:

#ComponentRoleGuide
1MariaDBDomain and alias lookup backendmail-forwarding-core
2DNSMX, SPF, DMARC, PTR recordsDNS Configuration
3PostSRSdSender Rewriting Scheme (SRS)mail-forwarding-core
4PostfixSMTP engine and policy enforcementmail-forwarding-core
5OpenDKIMDKIM signing (optional, recommended)mail-forwarding-core
6Node.js APIHTTP endpoints for alias managementmail-forwarding-api
7Next.js UIWeb frontend for end usersmail-forwarding-ui

The installation order is mandatory. Components 1–5 are covered in the mail-forwarding-core guide. Installing out of order will cause misleading failures.

Deployment Path

Deploy the core stack

Follow the mail-forwarding-core guide to set up MariaDB, DNS, PostSRSd, Postfix, and OpenDKIM.

Configure DNS for your domains

Use the DNS Configuration guide to properly set up PTR, MX, SPF, DMARC, and DKIM records.

Deploy the API

Follow the mail-forwarding-api guide to set up alias management endpoints.

Deploy the UI

Follow the mail-forwarding-ui guide to deploy the Next.js frontend.

Optional: Set up cleanup cronjob

Configure the cleanup cronjob to purge expired confirmation tokens.

Was this page helpful?
Built with Documentation.AI

Last updated today