discord-mcp
Provides read-only access to your own Discord DMs, group chats, and servers, with tools for full-text search, recent messages, listing channels, retrieving conversation history, and viewing attachments.
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., "@discord-mcpfind the PDF I was sent in my DMs last week"
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.
discord-mcp
An MCP server with read-only access to your own Discord: DMs, group chats and servers.
It stays connected to your account the way the desktop app does and keeps every message in a local SQLite cache with full-text search. Lookups hit the cache, not Discord; older history is fetched only when asked for, then cached.
Automating a user account is against Discord's Terms of Service. This only reads and behaves like a normal client, but use it at your own risk.
Tool | |
| Full-text search, optionally within one channel |
| Everything from the last N hours |
| Every DM, group and channel, most recent first |
| One channel in order, fetching older history as needed |
| Images the model can see, PDFs and text it can read, plus a download link |
Your token
In Discord on the web, open DevTools → Network, click any channel, and copy the Authorization header of a discord.com/api request. The server reads it from DISCORD_TOKEN. Treat it like your password; changing your password revokes it.
Related MCP server: Discord Analysis MCP
Use it locally
pip install -r requirements.txt
claude mcp add discord -e DISCORD_TOKEN=<token> -- python /path/to/discord-mcp/server.pyAny MCP client works the same way: run server.py as a stdio server with DISCORD_TOKEN set.
Host it
To reach it from anywhere (phone, web), run it over HTTP behind any HTTPS reverse proxy. Fill in .env from .env.example (your URL and an OAuth app so only you can sign in; a Discord app works with no extra config), then:
docker compose up -dAdd https://<your-domain>/mcp to your client as a remote server. The cache volume holds a copy of your messages, so keep the machine private.
Contributing
Issues and PRs welcome, including from agents using the server.
This server cannot be deployed
Maintenance
Related MCP Connectors
Search your AI chat history (ChatGPT, Claude, Codex) from any MCP client. Remote, private, read-only
Search and reason over your Obsidian-style Markdown vault, right from ChatGPT.
Mac & Windows: let ChatGPT, Claude & Cursor use your email, calendar, iMessage, Teams, files.
Give your agent live data from Twitter, Reddit, the web and GitHub. No API keys, no scraping stack.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables LLMs to send and read messages in Discord channels, manage servers, channels, and roles via Discord's API.11 npm2MIT
- AlicenseNot gradedqualityDmaintenanceEnables LLMs to read and write Discord messages, search content, and compute channel statistics via a Discord bot.MIT
- FlicenseNot gradedqualityDmaintenanceEnables LLMs to read messages, discover channels, send messages, and monitor Discord communities using the Discord HTTP API.-
- FlicenseNot gradedqualityCmaintenanceEnables AI agents to search and recall Discord conversations, analyze community activity, participation, and growth, and optionally send messages when writes are enabled.1-