gmail-mcp-multi
Allows managing multiple Gmail accounts, including searching, reading, sending, labeling, and deleting emails, with support for account aliases and batch operations.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@gmail-mcp-multi search for unread emails in my work account"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
gmail-mcp-multi
A Gmail MCP server with native multi-account support. Manage multiple Gmail accounts from a single server instance.
Unlike other Gmail MCPs that require running separate server instances per account, this one lets you specify which account to use on each tool call—making it easy to manage personal and work inboxes from Claude Code, Cursor, or any MCP client.
Features
Multi-account support - Single server instance, unlimited Gmail accounts
Account aliases - Use friendly names like "work" or "personal" instead of email addresses
Full Gmail API - Search, read, send, label, and manage emails
Batch operations - Bulk modify or delete emails efficiently
Auto token refresh - Handles OAuth token refresh automatically
Related MCP server: gmail-mcp
Installation
npm install -g gmail-mcp-multiOr run directly with npx:
npx gmail-mcp-multiQuick Start
1. Set up Google Cloud OAuth
You'll need OAuth credentials from Google Cloud Console:
Go to Google Cloud Console
Create a new project (or use existing)
Enable the Gmail API
Create OAuth 2.0 credentials (Desktop app type)
Download the credentials JSON
2. Configure the MCP
Create ~/.gmail-mcp/oauth-keys.json with your OAuth credentials.
3. Add to your MCP client
Claude Code (~/.claude/settings.json):
{
"mcpServers": {
"gmail": {
"command": "npx",
"args": ["gmail-mcp-multi"]
}
}
}4. Authenticate accounts
Once the MCP is running, use the authenticate tool:
authenticate({ alias: "work", email: "you@company.com" })
authenticate({ alias: "personal", email: "you@gmail.com" })5. Use it!
search_emails({ account: "work", query: "in:inbox is:unread" })
search_emails({ account: "personal", query: "from:mom" })Tools
All tools that interact with Gmail require an account parameter (alias or email).
Account Management
Tool | Description |
| List all configured accounts and auth status |
| Add or re-authenticate an account |
Email Operations
Tool | Description |
| Search emails using Gmail query syntax |
| Get full content of an email by ID |
| Send a new email |
| Create a draft |
| Add/remove labels, mark read/unread |
| Trash or permanently delete |
| Bulk label operations |
| Bulk delete |
Label Management
Tool | Description |
| Get all labels for an account |
| Create a new label |
| Delete a label |
Configuration
Credentials are stored in ~/.gmail-mcp/:
~/.gmail-mcp/
├── config.json # Account aliases and settings
├── oauth-keys.json # Your Google OAuth app credentials
└── accounts/
├── work/
│ └── credentials.json
└── personal/
└── credentials.jsonDevelopment
git clone https://github.com/dmorrill/gmail-mcp-multi.git
cd gmail-mcp-multi
npm install
npm run build
npm run devContributing
Contributions welcome! Please see CONTRIBUTING.md for guidelines.
License
MIT
Available Tools
7 toolsauthenticateA
Add or re-authenticate a Gmail account. Opens browser for OAuth flow.
Inputs: alias (required), email.
list_accountsA
List all configured Gmail accounts and their authentication status
Inputs: no named parameters.
list_labelsC
Get all labels for an account
Inputs: account (required).
modify_emailB
Modify email labels (add/remove labels, mark read/unread)
Inputs: account (required), messageId (required), addLabelIds, removeLabelIds.
read_emailB
Get the full content of an email by ID
Inputs: account (required), messageId (required).
search_emailsB
Search for emails using Gmail query syntax
Inputs: account (required), query (required), maxResults.
send_emailC
Send a new email
Inputs: account (required), to (required), subject (required), body (required), +2 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 7 tools
Each tool has a distinct purpose: authentication, account listing, label management, email reading, searching, sending, and label modification. No overlap or ambiguity.
All tool names follow a consistent verb_noun pattern with snake_case (e.g., list_accounts, modify_email). The only exception is 'authenticate' which lacks an object but is still clear.
7 tools is appropriate for a Gmail server, covering authentication, account management, label operations, and core email actions without being excessive or insufficient.
Core operations like send, read, search, and modify labels are present, but missing label creation/deletion and email deletion/trash are notable gaps for typical Gmail workflows.
Maintenance
Related MCP Connectors
A MCP server for Gmail that lets you search, read, and draft emails and replies.
Hosted MCP server for your Gmail, Outlook and IMAP mail, with mailboxes and scopes set per agent.
An MCP server that provides email capabilities, hosted on Alpic platform
An MCP server that provides email capabilities, hosted on Alpic platform
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceAn MCP server that provides read, label, and draft access to multiple Gmail accounts from a single server, never sending email.101 npmMIT
- FlicenseNot gradedqualityBmaintenanceEnables interacting with multiple Gmail accounts through a single MCP server, supporting search, labels, drafts, and thread management with per-account OAuth.1-
- FlicenseNot gradedqualityDmaintenanceMulti-user Gmail MCP server that enables sending/receiving emails, managing accounts, and searching mail via SMTP/IMAP with per-user isolation and encrypted app passwords.-
- FlicenseNot gradedqualityDmaintenanceMulti-account Gmail MCP server for reading threads, managing labels, and creating drafts across multiple Gmail accounts.-