How to Connect MCP Servers in Claude Desktop, Cursor & Windsurf
Connect live file systems, databases, GitHub, and browser automation to your AI assistants using the Model Context Protocol (MCP).
{
"mcpServers": {
"filesystem": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-filesystem", "/Users/username/Projects"]
},
"postgres": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-postgres", "postgresql://localhost/mydb"]
}
}
}
Key Takeaways & What You Need to Know
- Model Context Protocol (MCP) is the universal open standard (JSON-RPC 2.0) that connects AI assistants like Claude Desktop, Cursor, and Windsurf to external databases, tools, and code repositories.
- The GitHub and PostgreSQL MCP servers are the highest-impact additions for everyday development, eliminating manual context copy-pasting and enabling safe, schema-aware database inspection.
- Puppeteer and Brave Search give AI models real-time visibility into dynamic web pages, client-side rendering, and current 2026 API documentation without hallucination.
- Docker and Filesystem MCP servers turn isolated conversational bots into operational copilots capable of inspecting container logs, troubleshooting crashes, and managing project workspaces.
- Security hygiene is essential: always restrict filesystem servers to specific project directories and connect database servers using read-only roles with no write or drop privileges.
Quick Implementation Steps (4 Milestones)
20 min totalLocate Your MCP Configuration File
MCP servers communicate over stdio (standard input/output) or Server-Sent Events (SSE). Client applications configure servers via a central JSON file.
# On macOS (Claude Desktop):
code ~/Library/Application\ Support/Claude/claude_desktop_config.json
# On Windows (Claude Desktop):
notepad %APPDATA%\Claude\claude_desktop_config.json
# In Cursor IDE: Navigate to Cursor Settings > Features > MCP Servers
Add Filesystem & Local Database MCP Servers
Add the official Anthropic filesystem server and Postgres/SQLite server into the `mcpServers` object.
{
"mcpServers": {
"filesystem": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-filesystem", "/Users/sanketr/Projects"]
},
"github": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-github"],
"env": {
"GITHUB_PERSONAL_ACCESS_TOKEN": "ghp_yourTokenHere"
}
}
}
}
Restart Client & Inspect Available Tools
Completely quit Claude Desktop or Cursor and relaunch it. The client will spin up background child processes for each declared server.
# Inspect background node processes spawned by MCP:
ps aux | grep modelcontextprotocol
Execute Your First Multi-Tool Prompt
Test your assistant with a prompt that demands multiple autonomous tool calls in sequence.
Prompt to test:
"Inspect the schema of my projects in /Users/sanketr/Projects, find all files with TODO comments, and summarize them into a markdown table."
For years, using large language models felt like talking to an exceptionally brilliant software architect trapped inside a windowless bunker. You had to manually copy-paste code snippets, screenshot web pages, transcribe terminal errors back and forth, and write boilerplate SQL queries by hand just to give the model the context it needed.
In 2026, the Model Context Protocol (MCP) has completely eliminated this operational friction. Open-sourced by Anthropic and rapidly adopted by Claude Desktop, Cursor, Windsurf, Zed, Continue.dev, and Sourcegraph Cody, MCP has emerged as the universal "USB-C standard" of artificial intelligence. Instead of crafting fragile custom API integrations for every individual AI model, developers can now connect standardized MCP servers that grant AI assistants secure, real-time access to production codebases, staging databases, headless browsers, container daemons, and sprint trackers.
Whether you want your AI assistant to query live PostgreSQL tables, triage GitHub pull requests, scrape complex single-page web applications with Puppeteer, or inspect Docker container logs directly from your editor, here are the top 7 MCP servers every developer should connect in 2026—complete with battle-tested JSON configuration snippets, security guardrails, and real-world developer workflows.
Quick Answer: The 7 Essential MCP Servers in 2026
Top Developer MCP Servers at a Glance:
- 1. GitHub MCP Server (
@modelcontextprotocol/server-github): Inspect branches, search pull requests, review commits, and create issues directly from your AI agent. - 2. PostgreSQL MCP Server (
@modelcontextprotocol/server-postgres): Provides schema-aware, read-only SQL querying and query execution plan analysis over local or staging databases. - 3. Puppeteer MCP Server (
@modelcontextprotocol/server-puppeteer): Automates headless browser sessions, takes DOM screenshots, executes client-side JavaScript, and scrapes dynamic single-page applications. - 4. Brave Search MCP Server (
@modelcontextprotocol/server-brave-search): High-speed, privacy-first web search and documentation retrieval without search-engine tracking or API bloat. - 5. Docker MCP Server (
docker-mcp): Inspect running containers, tail service logs, restart failing microservices, and run containerized test suites. - 6. Filesystem MCP Server (
@modelcontextprotocol/server-filesystem): Secure, strictly sandboxed local disk access to search directories, read config files, and write project assets. - 7. Linear MCP Server (
linear-mcp): Connects AI reasoning directly to your sprint backlog, allowing agents to fetch user stories, assign bug tickets, and update issue statuses.
Benchmark Comparison Matrix: Top Developer MCP Servers
| MCP Server | Domain | Transport | Primary Superpower | Action |
|---|---|---|---|---|
|
GitHub MCP
Code Hosting
|
Source Control | stdio (Node/npx) | Search PRs, review code diffs & automate repo issues | Config → |
|
PostgreSQL MCP
Databases
|
Relational Data | stdio (Node/npx) | Live schema introspection & read-only query execution | Config → |
|
Puppeteer MCP
Headless Browser
|
Web Scraping | stdio (Node/npx) | Headless browser navigation, screenshots & JS DOM parsing | Config → |
|
Brave Search MCP
Web Discovery
|
Live Web Search | stdio (Node/npx) | Clean markdown search results with zero crawler tracking | Config → |
|
Docker MCP
DevOps & Containers
|
Infrastructure | stdio (Python/uvx) | Query container logs, inspect container health & restart pods | Config → |
|
Filesystem MCP
Local Storage
|
Local OS | stdio (Node/npx) | Strict path-scoped file read/write with sandboxed boundaries | Config → |
|
Linear MCP
Issue Tracking
|
Productivity | stdio / SSE | Sync sprint backlogs, auto-triage bugs & draft release notes | Config → |
What is Model Context Protocol? (The USB-C Architecture of AI)
To appreciate why MCP is revolutionizing developer workflows in 2026, consider the previous state of LLM tool calling. Every AI framework—LangChain, LlamaIndex, OpenAI Assistants, AutoGen—invented its own proprietary tool-calling schema. If a company built a Postgres integration for OpenAI, it did not work in Claude Desktop, Cursor, or Ollama without rewriting the entire abstraction layer.
Anthropic launched the Model Context Protocol (MCP) as an open-standard communication protocol built on lightweight JSON-RPC 2.0. The architecture consists of four distinct participants:
1. The MCP Host (Client)
The user-facing application hosting the AI model—such as Claude Desktop, Cursor, Windsurf, or Zed. The host negotiates capabilities and renders confirmation dialogs to ensure human oversight.
2. Transport Protocol
MCP communicates over two primary transport layers: stdio (standard input/output for local processes running via Node or Python) and Server-Sent Events (SSE) over HTTP for remote servers.
3. The MCP Server
A lightweight server process exposing three core primitives: Resources (passive context data), Tools (executable functions with parameter schemas), and Prompts (pre-built prompt templates).
1. GitHub MCP Server — Best for Pull Request Reviews & Repo Operations
Official Anthropic server connecting your AI directly to GitHub APIsThe GitHub MCP Server (@modelcontextprotocol/server-github) is arguably the single most impactful integration for everyday software engineers. Rather than navigating browser tabs back and forth, your AI assistant can directly interact with public and private repositories using your personal GitHub token.
What It Lets Your AI Do:
- Search & Inspect Pull Requests: Ask your AI: "Find all open pull requests touching the auth service in the last 7 days and summarize breaking changes."
- Deep File & Commit History Inspection: Retrieve commit diffs, inspect git blame metadata, and explore branch divergence without leaving your IDE.
- Automated Issue Creation: Generate well-structured bug reports complete with stack traces, environment specs, and reproduction steps directly from your chat terminal.
Claude Desktop Configuration:
{
"mcpServers": {
"github": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-github"],
"env": {
"GITHUB_PERSONAL_ACCESS_TOKEN": "ghp_yourPersonalAccessTokenHere"
}
}
}
}
2. PostgreSQL MCP Server — Best for Database Introspection & Safe Queries
Schema-aware database intelligence with read-only safety guardrailsDebugging backend issues almost always requires inspecting database states. Writing SQL queries while toggling between DBeaver, pgAdmin, and your code editor introduces friction. The PostgreSQL MCP Server (@modelcontextprotocol/server-postgres) gives your AI direct visibility into table schemas, foreign key constraints, indexes, and row counts.
What It Lets Your AI Do:
- Instant Schema Awareness: The AI automatically inspects table relationships and column data types before proposing migrations or writing complex ORM queries.
- Query Performance Optimization: Run
EXPLAIN ANALYZEon slow queries and have Claude suggest optimal composite indexes to eliminate sequential scans. - Safe Read-Only Data Verification: Confirm that newly seeded test fixtures exist in your local development Docker database without manual SQL typing.
Claude Desktop Configuration:
{
"mcpServers": {
"postgres": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-postgres",
"postgresql://readonly_user:password@localhost:5432/my_app_dev"
]
}
}
}
GRANT SELECT ON ALL TABLES IN SCHEMA public TO readonly_user;). Never provide superuser or write credentials to an LLM.
3. Puppeteer MCP Server — Best for Headless Browsing & Dynamic Scraping
Gives your AI an actual web browser to inspect JavaScript-heavy pages and take screenshotsStandard LLM web scrapers rely on naive curl or HTTP GET requests. When encountering modern single-page applications built with React, Vue, or Next.js, static scrapers return blank HTML shells. The Puppeteer MCP Server (@modelcontextprotocol/server-puppeteer) solves this by launching a genuine headless Chromium browser instance.
What It Lets Your AI Do:
- Execute Client-Side JavaScript: Waits for dynamic client rendering, hydration, and API calls to complete before inspecting the DOM.
- Automated Visual Screenshots: Instruct your assistant: "Navigate to http://localhost:3000/dashboard, take a viewport screenshot, and inspect for broken layout elements on mobile."
- Interactive Form Submissions: Fill out input fields, click buttons, select dropdowns, and test end-to-end user journeys programmatically.
Claude Desktop Configuration:
{
"mcpServers": {
"puppeteer": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-puppeteer"]
}
}
}
4. Brave Search MCP Server — Best for Fast, Privacy-Focused Web Discovery
Clean markdown search extracts without search engine bloat or tracking cookiesAI training data has a fixed cutoff date. When writing code with cutting-edge libraries released in 2025 or 2026, offline models hallucinate deprecated syntax. The Brave Search MCP Server (@modelcontextprotocol/server-brave-search) connects your assistant to Brave's independent web index.
What It Lets Your AI Do:
- Real-Time Documentation Lookup: Fetch the latest breaking changes and API migration guides for Next.js 16, Tailwind CSS v4, or Bun.
- Privacy-Preserving Search: Brave's API does not profile developers or build advertising profiles based on search queries.
- Generous Free Tier: Brave offers up to 2,000 free queries per month, easily satisfying the research needs of solo developers and small engineering teams.
Claude Desktop Configuration:
{
"mcpServers": {
"brave-search": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-brave-search"],
"env": {
"BRAVE_API_KEY": "BSA_yourBraveApiKeyHere"
}
}
}
}
5. Docker MCP Server — Best for Container Management & Microservice Triage
Inspect Docker daemon state, monitor container logs, and troubleshoot crashesModern microservice development requires running multiple Docker containers simultaneously—Redis caches, Postgres instances, RabbitMQ queues, and local API gateways. When a service crashes silently, tracking down the failure takes valuable time. The Docker MCP Server provides native control over your local Docker daemon.
What It Lets Your AI Do:
- Container Log Inspection: Ask your AI: "Why did the redis-cluster container exit with code 137? Inspect the last 100 log lines and recommend fix."
- Safe Service Restarts: Trigger restarts of individual crashed containers without resetting your entire docker-compose network.
- Image & Volume Management: Identify dangling Docker images and bloated volumes consuming disk space on your local development machine.
Claude Desktop Configuration:
{
"mcpServers": {
"docker": {
"command": "uvx",
"args": ["docker-mcp"]
}
}
}
6. Filesystem MCP Server — Best for Local Sandboxed Code & Config Auditing
Official Anthropic server providing strictly sandboxed access to local foldersWhile developer tools like Cursor already have built-in workspace search, general AI clients like Claude Desktop have zero local filesystem access by default. The official Filesystem MCP Server (@modelcontextprotocol/server-filesystem) gives Claude Desktop secure, explicitly whitelisted access to specified project folders.
What It Lets Your AI Do:
- Cross-Directory File Search: Fast fuzzy searching and regex pattern matching across project source files, stylesheets, and documentation.
- Read & Write Configuration: Review
package.json,tsconfig.json, and environment sample files with structured diff previews. - Strict Sandboxing Security: You specify the exact directory path. The server rejects any attempt to traverse outside the specified folder (blocking
../path traversal).
Claude Desktop Configuration:
{
"mcpServers": {
"filesystem": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-filesystem",
"/Users/yourname/Projects/my-app"
]
}
}
}
7. Linear MCP Server — Best for Sprint Management & Issue Backlog Triage
Bridge engineering code changes directly to product stories and sprint ticketsModern software development is not just writing code; it is coordinating work across engineering and product teams. The Linear MCP Server allows your AI agent to query current sprint backlogs, fetch issue details, link commits to issue identifiers, and automatically draft release notes.
What It Lets Your AI Do:
- Retrieve Active Sprint Tasks: Prompt your assistant: "Fetch all High Priority bugs assigned to me in the current cycle and outline the reproduction steps."
- Automate Ticket Status Updates: Once a feature PR is created, the AI agent can transition the Linear ticket to In Review and attach the pull request link.
- Draft Release Notes: Compile all completed issues in a milestone into a customer-facing markdown release changelog in seconds.
Claude Desktop Configuration:
{
"mcpServers": {
"linear": {
"command": "npx",
"args": ["-y", "@linear/mcp-server"],
"env": {
"LINEAR_API_KEY": "lin_api_yourLinearKeyHere"
}
}
}
}
Step-by-Step Setup Guide: Configuring MCP in Claude Desktop, Cursor & Windsurf
Setting up Model Context Protocol servers takes less than three minutes once you know where configuration files reside:
- Locate Your Client Config File:
- macOS (Claude Desktop):
~/Library/Application Support/Claude/claude_desktop_config.json - Windows (Claude Desktop):
%APPDATA%\Claude\claude_desktop_config.json - Cursor: Navigate to Settings → Features → MCP Servers or add to
.cursor/mcp.jsonin your project root. - Windsurf: Open Windsurf Settings → Cascade → Model Context Protocol.
- macOS (Claude Desktop):
- Ensure Node.js and Python Runtime Availability: Most standard MCP servers execute via
npx(Node 18+) oruvx(Python FastMCP). Verify by runningnode -vanduv --versionin your terminal. - Paste Your Merged JSON Configuration: Combine your chosen servers into a single
mcpServersobject. - Restart Your Client: Completely quit and relaunch Claude Desktop or Cursor. Look for the small hammer or plug icon in the bottom-right corner of the chat input to confirm active server connectivity.
Security Best Practices: Guarding Your Local Machine Against Agentic Exploits
Granting an artificial intelligence model access to execute commands on your local machine requires responsible security hygiene. Follow these non-negotiable rules:
1. Principle of Least Privilege
Never point the Filesystem MCP server at your home directory (~) or root folder (/). Restrict directory access strictly to active project workspaces (e.g. ~/Projects/my-app) so an errant prompt can never read SSH keys or browser cookies.
2. Never Hardcode Production Secrets
Do not pass write-access production database strings or administrative API tokens in client JSON configs. Use environment variables or dedicated staging credentials with read-only permissions.
Conclusion: The Connected AI Developer Stack in 2026
The Model Context Protocol has fundamentally redefined what is possible with artificial intelligence. By connecting your AI assistant to GitHub, PostgreSQL, Puppeteer, Docker, and Brave Search, you transform an isolated conversational chatbot into an autonomous engineering partner with full operational context.
Explore our complete Model Context Protocol Hub for more server tutorials, build your personalized AI tool stack in our AI Stack Builder, or compare the best developer environments in our AI Comparisons Directory.
How to Verify You Are Done (Checklist)
Before deploying to production or closing your session, check off each of the following milestones:
Tools used in this tutorial
-
Claude: pricing, pros and cons
Anthropic's assistant, with plans from free to a 10x-usage Ultra tier
-
Cursor: pricing, pros and cons
AI coding agent from Anysphere, now part of SpaceX, with Grok and third-party models
Frequently Asked Questions & Troubleshooting
Common questions, hardware sizing limits, and quick fixes tested across production setups.