100% on-premise — your email data never leaves your network

Email access control for
_

Transparent IMAP/SMTP proxy with fine-grained permission rules. Control exactly which emails can be read, sent, or deleted — with optional human-in-the-loop approval.

mailgator-config.toml
# Who can access email — and what they can do

[[rules]]
name       = "AI can read invoices"
folders    = ["Invoices"]
operations = ["mail:read"]
action     = "allow"

[[rules]]
name       = "Outbound requires approval"
operations = ["mail:send"]
action     = "ask"
ask_groups = ["security"]

[[rules]]
name   = "Deny everything else"
action = "deny"

# Who gets notified for approval
[ask.groups.security]
recipients = ["security@company.com"]

100%

On-premise

0 bytes

Email data we see

1 binary

No dependencies

TOML

Config as code

The problem with AI email access

AI agents need email access to be useful. But giving them full access is reckless.

90% over-permissioned

Most AI agents get full inbox access when they only need to read invoices. One prompt injection away from exfiltrating sensitive data.

No granular controls

App passwords are all-or-nothing. OAuth scopes are too broad. Email providers don't offer folder-level or sender-level restrictions.

Cloud proxies see your data

Enterprise DLP solutions route email through their servers. You're trusting a third party with every message. Mailgator runs on YOUR infrastructure.

How it works

Mailgator sits between your email client and your mail server. Invisible to both.

AI Agent / Client

IMAP / SMTP

mg

Mailgator

Rules & Filtering

Mail Server

Gmail, Fastmail, etc.

1

Configure rules

Write TOML rules: which folders, which senders, which operations. Allow, deny, or require human approval.

2

Point clients at the proxy

Change the IMAP/SMTP server address in your AI agent or email client to Mailgator's address. Everything else stays the same.

3

Stay in control

Mailgator enforces your rules transparently. The ask action lets you approve or deny sensitive operations via email or web UI.

Up and running in 2 minutes

terminal
# 1. Create config from template
$ mailgator config init
# 2. Edit your upstream server + rules
$ vim mailgator-config.toml
# 3. Activate your license
$ mailgator license login
✓ Browser opened — please log in at mailgator.io
✓ License saved (Pro, expires 2027-03-09)
# 4. Start the proxy
$ mailgator serve
✓ IMAP proxy listening on 0.0.0.0:143
✓ SMTP proxy listening on 0.0.0.0:587

Download Mailgator

Single binary. No dependencies. Just download and run.

Built for security-conscious teams

Everything you need to control AI email access. Nothing you don't.

Fine-grained rules

Filter by folder, sender, recipient, and operation type. Combine with allow, deny, or ask actions. First match wins.

Human-in-the-loop

The ask action pauses the operation and notifies you. Approve or deny via email reply or web UI.

Transparent proxy

Standard IMAP and SMTP. Works with any email client, any provider, any AI framework. No SDK, no API changes.

100% on-premise

Runs entirely on your infrastructure. Email credentials never leave your network. We only validate your license — zero data exposure.

Config as code

One TOML file. Version-controlled, reviewable, deployable. No web dashboard clutter — just clean infrastructure-as-code.

Single binary

Download, configure, run. No runtime dependencies. Written in Go for maximum portability and performance.

Simple pricing

One proxy. Fair prices. No per-seat nonsense.

Every plan starts with a free 7-day trial. No credit card required.

Limited launch offer

Pro

€6 €3 /month

€72 €36 billed annually

  • 3 mailboxes
  • 5 rules
  • Unlimited instances
  • Allow, deny & ask actions
  • Docker support
  • Priority support
Start free trial
Best value

Max

€20 €12 /month

€240 €144 billed annually

  • 30 mailboxes
  • 200 rules
  • Unlimited instances
  • Allow, deny & ask actions
  • Docker support
  • Priority support
Start free trial

Need more? Contact us for custom enterprise pricing.

Who uses Mailgator

DevOps & Platform Teams

CI/CD pipelines, monitoring alerts, and ticket systems that need email access. Mailgator gives you CLI-native, TOML-based access control that fits right into your infrastructure-as-code workflow.

$ mailgator serve -c /etc/mailgator/prod.toml

AI Agent Developers

Building agents that process email? Mailgator ensures your agent only accesses what it should. The ask action gives humans veto power over outbound emails — the missing safety net for autonomous agents.

# Agent connects to mailgator, not directly to Gmail

Take control of AI email access

One TOML file between total chaos and fine-grained control.