Skip to content
Grok

SMTP for Grok

io.github.ni-c/smtp-mcp

MCP server that sends mail over SMTP, gated behind an allowlist and a human confirmation

client:Grok transport:stdio runtime:npm

Install SMTP in Grok

.mcp.json (in your project root)

Held in this page only — never stored, logged, or sent anywhere but back to your screen.

{
  "mcpServers": {
    "smtp-mcp": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@ni-c/smtp-mcp"
      ],
      "env": {
        "SMTP_HOST": "<SMTP_HOST>",
        "SMTP_PORT": "<SMTP_PORT>",
        "SMTP_TLS": "<SMTP_TLS>",
        "SMTP_USER": "<SMTP_USER>",
        "SMTP_PASSWORD": "<SMTP_PASSWORD>",
        "SMTP_FROM": "<SMTP_FROM>",
        "SMTP_REPLY_TO": "<SMTP_REPLY_TO>",
        "SMTP_ALLOW_SEND": "<SMTP_ALLOW_SEND>",
        "SMTP_ALLOWED_RECIPIENTS": "<SMTP_ALLOWED_RECIPIENTS>",
        "SMTP_MAX_RECIPIENTS": "<SMTP_MAX_RECIPIENTS>",
        "SMTP_MAX_SENDS_PER_HOUR": "<SMTP_MAX_SENDS_PER_HOUR>",
        "SMTP_MAX_MESSAGE_BYTES": "<SMTP_MAX_MESSAGE_BYTES>",
        "SMTP_MAX_ATTACHMENT_BYTES": "<SMTP_MAX_ATTACHMENT_BYTES>",
        "SMTP_ATTACHMENT_DIR": "<SMTP_ATTACHMENT_DIR>",
        "SMTP_ATTACHMENT_TYPES": "<SMTP_ATTACHMENT_TYPES>",
        "SMTP_SIGNATURE": "<SMTP_SIGNATURE>",
        "SMTP_AUDIT_LOG": "<SMTP_AUDIT_LOG>",
        "SMTP_ALLOW_TOOLS": "<SMTP_ALLOW_TOOLS>",
        "SMTP_DENY_TOOLS": "<SMTP_DENY_TOOLS>",
        "SMTP_INSECURE_TLS": "<SMTP_INSECURE_TLS>"
      }
    }
  }
}

Grok Build reads Claude Code's .mcp.json and Claude Desktop's config unchanged, so a server you have already set up there needs nothing new. The Grok web app and X integration do not take custom servers. Grok docs

SMTP in other clients