stackoverflow
A Model Context Protocol server for querying Stack Overflow to help AI models find programming solutions
claude mcp add --transport stdio gscalzo-stackoverflow-mcp npx -y @gscalzo/stackoverflow-mcp \ --env STACKOVERFLOW_API_KEY="your-api-key-optional"
How to use
This MCP server provides a Stack Overflow search interface tailored for AI-assisted programming help. It exposes three main tools: search_by_error, search_by_tags, and analyze_stack_trace. You can query error messages to find relevant questions and answers, search by programming language or tags to surface related discussions, and analyze stack traces to extract potential solutions. Results can be returned in JSON or Markdown format depending on the request, and you can filter results by score, include comments, and control the number of results returned. If you want to increase request throughput, supply a Stack Overflow API key in the MCP settings to elevate rate limits.
How to install
Prerequisites:
- Node.js and npm installed on your system
- Access to run npm with npx or npm install -g
Installation options:
- Run directly with npx (no local install):
npx -y @gscalzo/stackoverflow-mcp
- Install globally with npm (optional):
npm install -g @gscalzo/stackoverflow-mcp
Configure the MCP server in your MCP settings file (examples shown in the README):
{
"mcpServers": {
"stackoverflow": {
"command": "npx",
"args": ["-y", "@gscalzo/stackoverflow-mcp"],
"env": {
"STACKOVERFLOW_API_KEY": "your-api-key-optional"
},
"disabled": false,
"autoApprove": []
}
}
}
Optional: place the config in the designated MCP settings path used by your environment (as shown in the README) and include your API key if you have one.
Additional notes
Notes:
- The server can operate without authentication but is rate-limited; providing a Stack Overflow API key increases limits.
- You can choose output format per request (JSON or Markdown).
- If you encounter network or API issues, verify that the API key (if set) is valid and that the host can reach stackoverflow endpoints.
- The MCP setting supports typical fields like disabled and autoApprove; adjust as needed for your environment.
Related MCP Servers
iterm
A Model Context Protocol server that executes commands in the current iTerm session - useful for REPL and CLI assistance
mcp
Octopus Deploy Official MCP Server
furi
CLI & API for MCP management
editor
MCP Server for Phaser Editor
DoorDash
MCP server from JordanDalton/DoorDash-MCP-Server
mcp
MCP сервер для автоматического создания и развертывания приложений в Timeweb Cloud