SMTP MCP Server
by ni-cio.github.ni-c/smtp-mcpv0.2.0
Send, reply to and forward mail over SMTP, restricted to a recipient allowlist, with each message approved by a person before sending.
context tax
queued
security
queued
cold start
queued
freshness
Active3d ago
Install SMTP MCP server
Install in Claude Code
claude mcp add smtp -e SMTP_HOST='<smtp-host>' -e SMTP_USER='<smtp-user>' -e SMTP_PASSWORD='<smtp-password>' -e SMTP_FROM='<smtp-from>' -- npx -y @ni-c/smtp-mcpInstall in Cursor
{
"mcpServers": {
"smtp": {
"command": "npx",
"args": [
"-y",
"@ni-c/smtp-mcp"
],
"env": {
"SMTP_HOST": "<smtp-host>",
"SMTP_USER": "<smtp-user>",
"SMTP_PASSWORD": "<smtp-password>",
"SMTP_FROM": "<smtp-from>"
}
}
}
}Add to ~/.cursor/mcp.json (global) or .cursor/mcp.json (project).
Install in Claude Desktop
{
"mcpServers": {
"smtp": {
"command": "npx",
"args": [
"-y",
"@ni-c/smtp-mcp"
],
"env": {
"SMTP_HOST": "<smtp-host>",
"SMTP_USER": "<smtp-user>",
"SMTP_PASSWORD": "<smtp-password>",
"SMTP_FROM": "<smtp-from>"
}
}
}
}Settings → Developer → Edit Config (claude_desktop_config.json), then restart.
Install in VS Code
{
"servers": {
"smtp": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@ni-c/smtp-mcp"
],
"env": {
"SMTP_HOST": "<smtp-host>",
"SMTP_USER": "<smtp-user>",
"SMTP_PASSWORD": "<smtp-password>",
"SMTP_FROM": "<smtp-from>"
}
}
}
}Add to .vscode/mcp.json in your workspace.
Install in Windsurf
{
"mcpServers": {
"smtp": {
"command": "npx",
"args": [
"-y",
"@ni-c/smtp-mcp"
],
"env": {
"SMTP_HOST": "<smtp-host>",
"SMTP_USER": "<smtp-user>",
"SMTP_PASSWORD": "<smtp-password>",
"SMTP_FROM": "<smtp-from>"
}
}
}
}Add to ~/.codeium/windsurf/mcp_config.json.
Configuration
| Variable | Required | Secret | Description |
|---|---|---|---|
| SMTP_HOST | yes | — | Hostname of the SMTP server, e.g. smtp.example.net. |
| SMTP_PORT | — | — | Port. Defaults to 587 for starttls, 465 for implicit, 25 for none. |
| SMTP_TLS | — | — | starttls (default), implicit or none. STARTTLS is required, never opportunistic. |
| SMTP_USER | yes | — | Username for SMTP authentication. |
| SMTP_PASSWORD | yes | yes | Password or app-specific password for SMTP authentication. |
| SMTP_FROM | yes | — | The only sender this server will use, e.g. "Name <person@example.net>". There is no from parameter. |
| SMTP_REPLY_TO | — | — | Reply-To header on every message, e.g. "Team <team@example.net>". Unset means no Reply-To header and replies go to SMTP_FROM. There is no reply_to parameter. |
| SMTP_ALLOW_SEND | — | — | Set to "true" to register the sending tools. Defaults to false: the server cannot send until it is set. |
| SMTP_ALLOWED_RECIPIENTS | — | — | Comma-separated addresses and @domains this server may write to. Required with SMTP_ALLOW_SEND=true; "*" allows any. |
| SMTP_MAX_RECIPIENTS | — | — | Maximum distinct recipients across To, Cc and Bcc in one message. Default 10. |
| SMTP_MAX_SENDS_PER_HOUR | — | — | Sliding hourly cap on messages sent. Default 20. |
| SMTP_MAX_MESSAGE_BYTES | — | — | Maximum size of the composed message. Default 10485760. |
| SMTP_MAX_ATTACHMENT_BYTES | — | — | Maximum size of a single attachment. Default 5242880. |
| SMTP_ATTACHMENT_DIR | — | — | Directory attachments are read from. Unset means attachments are unavailable. |
| SMTP_ATTACHMENT_TYPES | — | — | Comma-separated content types that may be attached. Defaults to a document and image allowlist. |
| SMTP_SIGNATURE | — | — | Text appended below the standard signature delimiter of every message. |
| SMTP_AUDIT_LOG | — | — | File the audit lines are appended to, in addition to stderr. |
| SMTP_ALLOW_TOOLS | — | — | Comma-separated tool names, a prefix with one trailing *, or "essential" for the curated preset. |
| SMTP_DENY_TOOLS | — | — | Comma-separated tool names or prefixes to remove, applied after SMTP_ALLOW_TOOLS. |
| SMTP_INSECURE_TLS | — | — | Set to "true" to accept self-signed certificates. Prefer a proper internal CA. |
Freshness
Active — last maintenance signal 3d ago. The newest of the signals below sets the band.
Last commit (default branch)
2026-10-06 · 3d ago · GitHub
Latest release
2026-09-07 · 32d ago · GitHub · v0.2.0
Package published
no data · npm/PyPI
Registry entry updated
2026-09-07 · 32d ago · official registry · v0.2.0
FAQ
›How do I install the SMTP MCP server in Claude Code?
Run: claude mcp add smtp -e SMTP_HOST='<smtp-host>' -e SMTP_USER='<smtp-user>' -e SMTP_PASSWORD='<smtp-password>' -e SMTP_FROM='<smtp-from>' -- npx -y @ni-c/smtp-mcp. For Cursor, VS Code, Claude Desktop and Windsurf, use the install tabs above.
›Does SMTP require an API key?
Yes. It expects SMTP_HOST, SMTP_USER, SMTP_PASSWORD, SMTP_FROM, of which 1 is a secret.
›Can I use SMTP as a remote (hosted) MCP server?
No hosted endpoint is published; it runs locally over stdio.
›Is SMTP in the official MCP registry?
Yes, as io.github.ni-c/smtp-mcp.
Alternatives to SMTP
Other communication MCP servers.