gmail-fan
Synchronizes Gmail and Google Workspace accounts locally and provides fast search over emails and messages.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
gmail-fan
Local-first macOS Gmail gateway: synchronize several Gmail or Google Workspace accounts into SQLite, search them quickly, and expose the same operations through a JSON CLI and a local stdio MCP server.
Gmail is the source of truth. OAuth tokens live in the macOS Keychain. There is no bundled model, embeddings index, or model-provider SDK.
Requirements
macOS (Keychain + LaunchAgent)
Bun 1.4 or newer
A Google Cloud project with the Gmail API enabled and an OAuth Desktop client JSON
Related MCP server: email-mcp
Install and first account
bun install
bun run build
bun src/cli/main.ts init --oauth-client ./client_secret.json
bun src/cli/main.ts accounts add --alias work
bun src/cli/main.ts sync
bun src/cli/main.ts search "quarterly planning" --jsonProduction paths:
~/Library/Application Support/gmail-fan/
~/Library/Logs/gmail-fan/Development
bun install
bun run test:unit
bun run test:integration
bun run typecheck
bun run check
bun run buildArchitecture
Gmail accounts
↓
Gmail API + separate OAuth grant per account
↓
Synchronization service
↓
SQLite + FTS5
↓
Shared application service layer
↓
CLI Local MCP server (stdio)Decisions: docs/adr. Security: docs/security.md. CLI: docs/cli.md. MCP: docs/mcp.md. Demo: docs/demo.md.
This server cannot be deployed
Maintenance
Related MCP Connectors
Your IMAP mailbox as an MCP server: read, search and (if you allow it) organize mail. Open source.
Email infrastructure for AI agents — send, receive, search, and reply to email over MCP.
Programmable email inbox for AI agents — JMAP, PoW auth, stdio MCP server.
Hosted email MCP for your own Gmail, Outlook.com, Microsoft 365, iCloud or IMAP inbox: read, search, draft, reply in thread, forward and file mail. It moves or flags up to 500 messages in one call, and a send leaves exactly one copy in Sent. A calendar is a separate connection, and connecting one adds diary and scheduling tools.
Related MCP Servers
- AlicenseBqualityCmaintenanceMulti-account Google MCP server providing read access to Gmail and Calendar via stdio. Supports secure authentication for personal and work accounts with OAuth and keychain token storage.4MIT
- AlicenseAqualityDmaintenanceLocal MCP server for multi-account IMAP/SMTP email (iCloud + Gmail via app-specific passwords). Never marks mail read. Cross-folder search, idempotent sends, TLS verified.8MIT
- AlicenseNot gradedqualityDmaintenanceA self-hostable Gmail MCP server that enables Gmail search/read, sending, replies, drafts, labels, and attachment downloads via MCP tools with OAuth authorization. Supports stdio and streamable HTTP transports.MIT
- FlicenseAqualityAmaintenanceA local stdio MCP server that gives any MCP client one connection to all of the user's Gmail, Google Workspace and IMAP accounts at once, letting assistants list accounts, read messages and attachments, run full-text search across mailboxes, trigger syncs and export messages as .eml. It runs on the user's own computer with encrypted secrets and no intermediary server, so mail is fetched directly from the providers.91-