Overview
The Enhanced Gmail MCP Server is a powerful Model Context Protocol (MCP) server designed for Gmail integration, enabling AI assistants to manage emails through natural language.
To use the server, clone the repository, set up a virtual environment, install the package, and configure it with your Google Cloud credentials.
- Complete email management including sending, reading, and organizing emails. - Draft management for creating and editing email drafts. - Advanced label management for organizing emails with custom labels. - Powerful search and filtering capabilities for efficient email retrieval. - Archive management to keep your inbox organized without deleting emails.
- Automating email responses using AI.
- Organizing emails by creating and applying labels.
- Searching for specific emails using advanced queries.
- Managing drafts for later review and sending.
Add to your AI client
Use these steps to connect Enhanced Gmail MCP Server in Cursor, Claude, VS Code, and other MCP-compatible apps. The same JSON appears in the Use with menu above for one-click copy.
Cursor
Add this to your .cursor/mcp.json file in your project root, then restart Cursor.
.cursor/mcp.json
{
"mcpServers": {
"gmail-mcp-theposch": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-gmail-mcp-theposch"
]
}
}
}Claude Desktop
Add this server entry to the mcpServers object in your Claude Desktop config, then restart the app.
~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows)
{
"mcpServers": {
"gmail-mcp-theposch": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-gmail-mcp-theposch"
]
}
}
}Claude Code
Add this to your project's .mcp.json file. Claude Code will detect it automatically.
.mcp.json (project root)
{
"mcpServers": {
"gmail-mcp-theposch": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-gmail-mcp-theposch"
]
}
}
}VS Code (Copilot)
Add this to your .vscode/mcp.json file. Requires the GitHub Copilot extension with MCP support enabled.
.vscode/mcp.json
{
"servers": {
"gmail-mcp-theposch": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-gmail-mcp-theposch"
]
}
}
}Windsurf
Add this to your Windsurf MCP config file, then restart Windsurf.
~/.codeium/windsurf/mcp_config.json
{
"mcpServers": {
"gmail-mcp-theposch": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-gmail-mcp-theposch"
]
}
}
}Cline
Open Cline settings, navigate to MCP Servers, and add this server configuration.
Cline MCP Settings (via UI)
{
"mcpServers": {
"gmail-mcp-theposch": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-gmail-mcp-theposch"
]
}
}
}FAQ
Can I use this server with any email account?
No, it is specifically designed for Gmail accounts with the Gmail API enabled.
Is there a cost associated with using the Enhanced Gmail MCP Server?
The server itself is free to use, but you may incur costs from Google Cloud services.
What programming language is used for this project?
The server is written in Python.7:["$","div",null,{"className":"container mx-auto flex flex-col gap-4","children":["$L26","$L27",["$","$L28",null,{"currentProject":{"id":1925,"uuid":"618c894b-720d-4a42-96ce-c09edb96759f","name":"gmail-mcp","title":"Enhanced Gmail MCP Server","description":"A Gmail MCP server","avatar_url":"https://avatars.githubusercontent.com/u/5529148?v=4","created_at":"2025-03-05T06:07:41.404Z","updated_at":"2025-03-12T10:21:44.841Z","status":"created","author_name":"theposch","author_avatar_url":"https://avatars.githubusercontent.com/u/5529148?v=4","tags":"gmail-mcp,email-management,ai-assistant","category":"research-and-data","is_featured":false,"sort":1,"url":"https://github.com/theposch/gmail-mcp","target":"_self","content":"$29","summary":"$2a","img_url":null,"type":null,"metadata":"{\"star\":\"0\",\"license\":\"GPL-3.0 license\",\"language\":\"Python\",\"is_official\":false,\"latest_commit_time\":\"2025-02-28 09:16:30\"}","user_uuid":null,"tools":null,"sse_url":null,"sse_provider":null,"sse_params":null,"is_official":false,"server_command":null,"server_params":null,"server_config":null,"allow_call":false,"is_innovation":false,"is_dxt":false,"dxt_manifest":null,"dxt_file_url":null,"is_audit":false},"randomProjects":[],"currentServerKey":"$undefined"}]]}]