Case Study
Kestrel: self-hosted mail and calendar that stay yours
Private mail and calendar suite with a keyboard-driven interface. Provider integrations run as sandboxed WASM plugins. In development at v0.3.3.
Check at: kestrel.yomite.in. Status is v0.3.3, in development.
I like apps with great interfaces, and I like desktop apps, because browsers come and go while a desktop app and its workflows stay put. Kestrel is the mail and calendar suite I wanted to live in. It is built for people who treat email as infrastructure: self-hosters, professionals who distrust clouds, anyone who kept keyboard habits and wants them respected.
How it started
I loved Notion Calendar. It looked great and it put my Notion tasks on the calendar itself. When Notion Mail was announced, I waited for the Windows desktop app and the Android app. Before either landed, Notion announced the shutdown of Notion Mail altogether.
Around the same time the Calendar app started lagging and crashing on me. I went looking for alternatives and found the same gaps everywhere. The interfaces were dull or not to my taste, the workflows did not fit mine, and the good ones cost more than mail deserves. Usually all three at once.
I already triage mail with agentic workflows, so the technical side did not scare me. And I had shipped this way before, on college projects plus Calculators Hub and StyleSwipe. So I decided to build the apps myself, and I prototyped the interface in Figma and Stitch first to lock the look before writing product code. I build solo with agentic workflows. Prototypes carry the design intent, agents carry the implementation volume, and I hold the product calls.
What it is
Two apps, kestrel-mail and kestrel-calendar, that open in under a second, work offline and answer the keyboard first. The theme is dark-only Kestrel Slate, shortcuts rebind in settings, and on mobile the sidebar becomes a bottom tab bar.
The architecture, simplified:
graph TD
Mail[kestrel-mail] --> Daemon[Sync daemon]
Cal[Calendar app] --> Daemon
Daemon --> Server[Axum backend]
Server --> Vault[Server-side<br/>token vault]
Gmail[Gmail WASM<br/>sandbox] --> Daemon
Outlook[Outlook WASM<br/>sandbox] --> Daemon
Mail --> Local[Local cache<br/>and queue]
Cal --> Local
What works today:
- Mail with J/K threading, a Cmd+K palette, a Notion-style peek panel, labels and folders, full-text search and a compose modal.
- Calendar with week, day and month views, drag-to-create and drag-to-resize on the timeline, recurring events and a mini-calendar sidebar.
- Live Gmail and Outlook sync for mail plus calendar through provider plugins.
- An offline queue that replays on reconnect, so old mail stays readable with no signal.
- Attachments saved to the OS download folder,
kestrel://deep links for OAuth return, and native notifications with reply, archive and snooze actions.
What is still mocked or planned: SMTP and API sending, snooze (currently archive), rich-text signatures, push over FCM and APNs, mobile code signing and auto-update. No users yet by design. Sending and signing come before anyone should depend on it, and reading plus triage is the daily workflow that comes first, so sending waits as the v0.4 milestone.
Decisions that held
These calls survived contact with implementation. Each one constrained later choices and paid off.
Offline first
I want old mail without internet: the location buried in a thread when the signal drops, or tickets at an event gate while the network struggles. Kestrel keeps a local cache and a mutation queue in kestrel_queue.db, so you can archive on a plane and it syncs on landing. Offline is the default state, not an error state.
Small and fast
A mail app should sip resources, so the backend is Rust with Axum and there is no Electron and no bundled browser per app. That choice forced the next one, because Rust needs a client story.
Your tokens never leave your server
OAuth refresh happens in a server-side provider token vault, and each app holds its own bearer plus keychain session. Nothing syncs through a vendor cloud because there is no vendor cloud.
New providers cannot break your mail
Gmail and Outlook run as WebAssembly plugins under Wasmtime, the WebAssembly runtime, against a wit/kestrel.wit interface. A broken provider build crashes its sandbox, not the daemon. Each mail app authenticates separately, so Mail and Calendar never share sessions.
Keyboard first, mouse second
Navigation runs on J/K, actions on Cmd+K, and calendar views on single keys. Email bodies render in sandboxed iframes so a hostile message cannot touch app state. Speed is the feature and everything else serves it.
Start small
The backend speaks SQLite and PostgreSQL, with adapters in sqlx switching on DATABASE_URL. A home server starts on a single file with full-text search, and the same binary moves to Postgres when the household outgrows it. Multi-tenancy covers a family, not a SaaS.
Decisions that bent
Two calls broke under real constraints and got replaced. Both replacements unlocked the project.
Standalone first, then a backend
I started wanting pure standalone apps with no server at all. Sync and notifications killed that plan, because neither stays reliable without something always on. So the backend exists for exactly those two jobs, cross-device sync and push, while everything a single device can do alone stays local.
Why Tauri and Svelte won
I evaluated Flutter and Kotlin Multiplatform first, and two problems stopped both: no component libraries I liked, and with Flutter the backend setup still sitting unsolved. Apps alone would have gone to Flutter for ease, or KMP since my deepest backend years are Java and Kotlin. But the project needed a server, and Tauri resolved both sides at once, with web frameworks carrying the interface and AI writing the UI layer while I owned the functionality underneath. Svelte beat React on weight and gave me something new to learn. The user-facing payoff: apps that open in under a second on a fraction of Electron’s memory. Skeleton UI components plus Kestrel Slate tokens produced that surface from shared parts, directed by my prototypes, while my backend and DevOps background stayed where it earns most, on the server, the sync and the packaging.
Shipping
One Axum backend serves both frontends, with sync over SSE, server-sent events, plus a background daemon. CI builds every target on merge to main. Tests run at three levels: Rust integration, 34 frontend suites, Playwright flows.
What is next
v0.3.3 builds everywhere and proves the shape. What comes next, in order:
- Finish the send loop. Real SMTP and API sending plus rich-text signatures, so the compose modal becomes a mailbox instead of a draft pad.
- Earn the home screen. Signed mobile builds, push notifications and auto-update, so the apps can live next to Gmail and hold their own.
- Grow the household. Contacts, CalDAV exposure and custom IMAP providers, each arriving as a new plugin with no changes to the server.
The next plugin decides whether the boundary holds.
Written by
Prathamesh Pathak
Building AI-native products. Writing about PM craft, career growth, and shipping.
Visit LinkedIn →More case studies
Cloud coder: selling dev tools to non-dev companies
Week one showed over ten lakh rupees in monthly recurring pipeline. AI coding environments for agencies and non-engineering firms, scoped tight for launch.
OK analytics: the funnel before the fix
OK leadership flew blind on pricing, carts and catalog. I scoped a 5-week Mixpanel integration across client and server with identity stitching and nine answered business questions.