Skip to content

TabMail/tabmail-ios

TabMail for iOS

An AI-native, open-source email client for iPhone.

Download on the App Store License: MPL 2.0 Swift 6 Platform: iOS 26+

TabMail brings summaries, drafting, triage, and a chat agent to your existing Gmail, Outlook/Microsoft, iCloud, and generic IMAP accounts. It is a native SwiftUI app built for iOS 26 with Swift 6 strict concurrency.

License: Mozilla Public License 2.0 (MPL-2.0). The "TabMail" name and logo are trademarks — see TRADEMARKS.md.


What's open, what's hosted

This repository is the complete iOS client — the full app, notification service, on-device search, and tests. It is genuinely open source under MPL-2.0.

The app talks to the TabMail backend over HTTPS for AI orchestration, push notifications, device sync, and billing. That hosted service (and its prompt content) is a separate, closed-source product. Open-sourcing the client does not expose it — but if you fork TabMail, you can point the app at your own backend by changing the endpoints and supplying your own keys (see Secrets.xcconfig.example).

The sibling components are open source too:

Highlights

  • On-device search — hybrid keyword + semantic search using a bundled Core ML embedding model and a vendored SQLite vector extension. No message bodies leave the device for indexing.
  • Optimistic, crash-safe sync — user actions persist locally before the UI acknowledges them and replay across crashes, kills, and reconnects; the server remains the source of truth on conflict.
  • Bring Your Own Key (BYOK) — route AI requests through your own OpenAI, Anthropic, or Google API key.
  • Push for Gmail, Outlook, and generic IMAP (via IDLE), with an iOS Notification Service Extension that fetches new mail in the background.

Building

Requirements:

  • Xcode 16+ (iOS 26 SDK)
  • XcodeGenbrew install xcodegen. The .xcodeproj is generated from project.yml and is not committed.

Steps:

  1. Clone this repository.
  2. Package dependencies (SwiftMail, SwiftSoup, GRDB) are resolved automatically from GitHub by Swift Package Manager — no manual checkout needed. (TabMail uses a BSD-2-Clause fork of SwiftMail at github.com/TabMail/SwiftMail.)
  3. Create your secrets file from the template and fill in your own values:
    cp Secrets.xcconfig.example Secrets.xcconfig
    Secrets.xcconfig is gitignored. The comments in the template explain how to obtain each OAuth client ID and how to generate the keys.
  4. Generate and open the project:
    ./Scripts/xcodegen.sh
    open TabMail.xcodeproj
    Use ./Scripts/xcodegen.sh rather than a bare xcodegen generate — it sources your DEVELOPMENT_TEAM from Secrets.xcconfig and passes it to XcodeGen so code signing resolves for every target, including the notification-service extension.
  5. Build and run the TabMail scheme on an iOS 26 simulator or device.

Run the tests with ⌘U, or:

xcodebuild -project TabMail.xcodeproj -scheme TabMail \
  -destination 'platform=iOS Simulator,name=iPhone 17 Pro' test

Project layout

Path What
TabMail/ The main app (SwiftUI views, view models, services, on-device search)
Shared/ Code shared between the app and the notification service
TabMailNotificationService/ Notification Service Extension (background IMAP fetch)
TabMailTests/ Unit tests
TabMailScreenshots/ UI-test screenshot harness
TabMail/Vendor/sqlite-vec/ Vendored SQLite vector extension (third-party)
Scripts/ Developer utilities (e.g. Core ML model conversion)

Contributing

Contributions are welcome under MPL-2.0. We use the Developer Certificate of Origin — every commit must be signed off with git commit -s. See CONTRIBUTING.md for setup and the full DCO text, and CODE_OF_CONDUCT.md for community expectations.

Security

Found a vulnerability? Please report it privately per SECURITY.md — do not open a public issue.

License

MPL-2.0. Third-party components retain their own licenses, listed in THIRD_PARTY_LICENSES.md.

Packages

 
 
 

Contributors

Languages