Mailgun MCP
A Model Context Protocol server implementation that enables AI assistants like Claude Desktop to interact with Mailgun email services, allowing users to send emails and visualize email delivery statistics through natural language.
What is Mailgun MCP?
Mailgun MCP is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to model context protocol server implementation that enables ai assistants like claude desktop to interact with mailgun email services, allowing users to send emails and visualize email delivery statisti...
A Model Context Protocol server implementation that enables AI assistants like Claude Desktop to interact with Mailgun email services, allowing users to send emails and visualize email delivery statistics through natural language.
This server falls under the Communication category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- A Model Context Protocol server implementation that enables
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx mailgun-mcp-serverConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use Mailgun MCP
The Mailgun MCP Server is an official Mailgun integration for AI assistants that exposes the full breadth of Mailgun's email API through the Model Context Protocol, covering message sending and retrieval, domain verification, webhook management, template creation with versioning, analytics and delivery statistics, suppression list management, mailing lists, inbound routing rules, and dedicated IP pool configuration. It is maintained by Mailgun directly, ensuring the tools stay current with the API. Developers and marketing teams use it to send transactional emails, debug delivery issues, and analyze email engagement through natural language without writing API calls.
Prerequisites
- Node.js 18+ with npm installed
- A Mailgun account with at least one verified sending domain at https://app.mailgun.com
- A Mailgun API key from the Mailgun dashboard (Settings > API Keys)
- An MCP-compatible client such as Claude Desktop or Claude Code
Get your Mailgun API key
Log in to the Mailgun dashboard, navigate to Settings > API Keys, and copy your Private API key. Note your account region (US or EU) as it affects the API endpoint.
Add the server to your MCP client config
Edit your claude_desktop_config.json to register the Mailgun MCP server with your API key and region.
{
"mcpServers": {
"mailgun": {
"command": "npx",
"args": ["-y", "@mailgun/mcp-server"],
"env": {
"MAILGUN_API_KEY": "your-mailgun-api-key",
"MAILGUN_API_REGION": "us"
}
}
}
}Optionally restrict to specific tool categories
Use the --tags flag in args to limit which tools are exposed. Valid tags are: send, validate, optimize, inspect. This reduces the tool list for focused use cases.
"args": ["-y", "@mailgun/mcp-server", "--tags", "send,inspect"]Restart Claude Desktop
Fully quit and reopen Claude Desktop to activate the Mailgun server. On macOS the config is at ~/Library/Application Support/Claude/claude_desktop_config.json.
Send a test email
Ask Claude to send a test email through your verified Mailgun domain to confirm the integration is working end-to-end.
Mailgun MCP Examples
Client configuration
Full claude_desktop_config.json entry for the official Mailgun MCP server.
{
"mcpServers": {
"mailgun": {
"command": "npx",
"args": ["-y", "@mailgun/mcp-server"],
"env": {
"MAILGUN_API_KEY": "your-mailgun-private-api-key",
"MAILGUN_API_REGION": "us"
}
}
}
}Prompts to try
Example natural language prompts for Mailgun operations.
- "Send an email to [email protected] with subject 'Your order has shipped' from [email protected]"
- "Show me a chart of email delivery statistics for yourdomain.com over the past 7 days"
- "Check DNS verification status for yourdomain.com and list any missing records"
- "Summarize all unsubscribes and complaints for yourdomain.com this month"
- "Create an email template called 'welcome' with a personalized greeting and a CTA button"Troubleshooting Mailgun MCP
401 Unauthorized when sending emails
Verify MAILGUN_API_KEY is your Private API key, not your Public Validation key. Also confirm MAILGUN_API_REGION matches your account — EU accounts must use 'eu', not the default 'us'.
Emails not delivered (queued but no delivery event)
Confirm your sending domain is fully verified in the Mailgun dashboard. Check DNS records for SPF, DKIM, and MX. Ask Claude to use the domain verification tool to identify missing DNS entries.
Tool not found errors for specific Mailgun operations
If you used --tags to restrict tools, the requested tool may be excluded. Either remove the tag filter or add the relevant tag (e.g., 'send' for message operations) to the args array.
Frequently Asked Questions about Mailgun MCP
What is Mailgun MCP?
Mailgun MCP is a Model Context Protocol (MCP) server that model context protocol server implementation that enables ai assistants like claude desktop to interact with mailgun email services, allowing users to send emails and visualize email delivery statistics through natural language. It connects AI assistants to external tools and data sources through a standardized interface.
How do I install Mailgun MCP?
Follow the installation instructions on the Mailgun MCP GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with Mailgun MCP?
Mailgun MCP works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is Mailgun MCP free to use?
Yes, Mailgun MCP is open source and available under the Apache 2.0 license. You can use it freely in both personal and commercial projects.
Mailgun MCP Alternatives — Similar Communication Servers
Looking for alternatives to Mailgun MCP? Here are other popular communication servers you can use with Claude, Cursor, and VS Code.
Slack
★ 86.1kEnables interaction with Slack workspaces through comprehensive channel management, messaging, user management, file uploads, and Block Kit formatting. Features secure credential storage via macOS Keychain and supports all major Slack operations incl
LibreChat
★ 37.3kEnhanced ChatGPT Clone: Features Agents, MCP, DeepSeek, Anthropic, AWS, OpenAI, Responses API, Azure, Groq, o1, GPT-5, Mistral, OpenRouter, Vertex AI, Gemini, Artifacts, AI model switching, message search, Code Interpreter, langchain, DALL-E-3, OpenA
Note Gen
★ 11.9kA cross-platform Markdown AI note-taking software.
DeepChat
★ 5.8k🐬DeepChat - A smart assistant that connects powerful AI to your personal world
WhatsApp MCP
★ 5.7kConnects AI assistants to the official Meta WhatsApp Cloud API for managing conversations and sending various message types through natural language. It provides tools for media management, template messages, and real-time webhook processing without
Apple
★ 3.1kEnables interaction with Apple apps like Messages, Notes, and Contacts through the MCP protocol to send messages, search, and open app content using natural language.
Browse More Communication MCP Servers
Explore all communication servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up Mailgun MCP in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use Mailgun MCP?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.