Launch AI Works
InsightsNov 12, 20263 min read

Perch: A Single‑Binary Mailbox for Small‑Business Email Automation

Perch combines a mailbox server, client, and agent‑ready CLI in a single file, removing the need for complex mail infrastructure.

LBy Launch AI Works
Perch: A Single‑Binary Mailbox for Small‑Business Email Automation
The short version

Perch runs as a single CGO‑free Go binary with embedded SQLite, letting you host IMAP and SMTP without opening inbound ports. mxRaven’s free tier provides 1,000 inbound and 1,000 outbound messages per month, handling MX, DKIM, SPF, DMARC, and spam filtering.

What Perch Is

Perch is an open‑source mailbox service distributed as one CGO‑free Go binary that embeds SQLite with full‑text search (FTS5). The binary implements both an IMAP server and an authenticated SMTP server, so you can point standard clients such as Thunderbird, Apple Mail, or mutt at it. Because the whole stack lives in a single file, there is no need to run Postfix, Dovecot, Rspamd, or any container orchestration, according to mxRaven.

The project is licensed under MIT‑0 and the source is hosted on GitHub. mxRaven supplies the public edge — MX records, SPF/DKIM/DMARC/ARC signing, IP reputation, and spam filtering — while Perch runs entirely on your hardware. The free mxRaven plan includes one workspace with 1,000 inbound and 1,000 outbound emails each month, no credit card required, as noted on the product site.

How the Public Edge Works

Inbound mail never reaches your network directly. mxRaven receives the message on the public internet, performs reputation checks and spam filtering, then pushes the mail to your Perch instance over an outbound WebSocket connection. This design means Perch can operate behind NAT, CGNAT, or a home router without any inbound SMTP ports exposed, a point emphasized by mxRaven.

mxRaven does not retain your messages after delivery; the mail is stored only in your local SQLite database or, optionally, offloaded as raw .eml files to an S3‑compatible bucket such as R2 while metadata and search indexes stay on‑premise. This gives you full control over retention and compliance.

Running Perch Behind NAT and Storing Mail

Because the inbound path is a client‑initiated WebSocket, you can start Perch on an old workstation, a Raspberry Pi, or any machine that can make outbound HTTPS connections. There is no requirement for a static public IP or port forwarding, which reduces operational overhead for small teams.

Storage options are flexible: keep everything in the embedded SQLite file for simplicity, or stream raw .eml blobs to object storage while the searchable index remains local. Both approaches keep the data under your governance and avoid vendor lock‑in.

Agent‑Friendly CLI for Automation

Perch ships a POSIX‑style command‑line interface that outputs NDJSON, raw .eml, mbox, or Maildir formats with proper exit codes. This makes it trivial to wire email into scripts, CI pipelines, or LLM agents. The project also provides an Agent Skill that can be installed via `npx skills add https://github.com/synqronlabs/perch –skill perch`, giving an agent a real inbox without browser automation or proprietary APIs.

Typical automation flows include searching for unseen messages (`perch mail search -q ‘unseen from:alice’ –json`), fetching the full message for retrieval‑augmented generation (`perch mail fetch –uids 42 message.eml`), and sending replies with attachments in a single command (`perch mail send –to [email protected] –subject ‘Report ready’ –body ‘See attached.’ –attach report.pdf`). These capabilities let a small business replace manual sorting and routing with reliable, scriptable workflows.

Takeaways

  • Perch eliminates the need for a traditional mail stack by delivering IMAP, SMTP, storage, and a CLI in one binary.
  • mxRaven’s free tier handles the public‑facing MX, authentication, reputation, and spam filtering, giving you 1,000 inbound and 1,000 outbound messages per month at no cost.
  • The outbound WebSocket inbound path lets you run Perch behind any NAT or firewall without opening ports, and the CLI makes email automation straightforward for scripts or AI agents.
L

Launch AI Works builds practical AI and automation inside small businesses. Notes in Insights are written from sources we cite and checked before publishing.

Your turn

Where would this work in your business?

Take the two-minute AI Opportunity Snapshot and we will point to where automation is most likely to pay off for you.

2mFree AI Opportunity Snapshot →

Get the Launch AI Works weekly

One email each week: practical AI for small business, plus what we’re building — the tools and workflows we’re testing in the real world.

By subscribing, you’ll receive one weekly email from Launch AI Works with practical AI ideas for small business and updates on what we’re building. We never sell or share your information. Unsubscribe anytime with one click in any email. See our privacy policy.