MCP — the protocol that connects
AI to every tool in the world
The Model Context Protocol (MCP) is an open standard developed by Anthropic — a sort of "USB-C for the AI world". Instead of writing a special integration for each tool, MCP gives Claude (and other models) access to tools, files, databases and APIs in a uniform, universal way.
What is MCP and why does it matter?
Before MCP, anyone who wanted to connect AI to an external tool — Slack, GitHub, a database, files — had to write an integration from scratch, custom for each model and each service. Endless duplicate work, hard maintenance, and incompatibility.
MCP solves this elegantly: a uniform communication protocol (JSON-RPC over stdio or SSE) that defines how AI Clients (like Claude Desktop, Cursor, Windsurf) talk to MCP Servers that expose tools, resources and prompts.
Cursor, Windsurf
stdio / SSE
DB, Files, API
MCP vs Function Calling
Function Calling (found in OpenAI and Anthropic) lets AI invoke functions — but those functions are defined in the prompt and run on the client side. MCP is a layer above that: the tools live in a separate server, are managed separately, and can be connected to any AI client that supports the protocol.
How MCP works — under the hood
The three primitives of MCP
Transport Layers — how the Client and Server communicate
- stdio — the most common. The server runs as a subprocess, communicating via stdin/stdout. Fast and simple, suited to local servers.
- SSE (Server-Sent Events) — for remote servers running over HTTP. Allows remote connection and sharing a server between multiple clients.
- Streamable HTTP — the next generation of SSE. Supports bidirectional signals and is improved for performance.
Connecting MCP to Claude Desktop
Claude Desktop is Anthropic's official MCP client. Configuring MCP servers is done through a single JSON file.
The config file location
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
The file structure
{
"mcpServers": {
"filesystem": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-filesystem",
"/Users/yourname/Documents"
]
},
"github": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-github"],
"env": {
"GITHUB_PERSONAL_ACCESS_TOKEN": "ghp_..."
}
},
"brave-search": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-brave-search"],
"env": {
"BRAVE_API_KEY": "BSA..."
}
}
}
}
Changes to config.json aren't loaded dynamically. You need to close and reopen the app. When the connection succeeds you'll see a hammer icon (🔨) in the chat interface — a sign the tools are available.
5 servers worth adding right away
@modelcontextprotocol/server-filesystem
@modelcontextprotocol/server-brave-search
@modelcontextprotocol/server-github
@modelcontextprotocol/server-postgres
@modelcontextprotocol/server-memory
MCP with Cursor and Windsurf
Both Cursor and Windsurf support MCP and let the code editors access external tools directly from Agent Mode. This is especially powerful when developing — Claude in Cursor can send metrics to Datadog, open tickets in Jira, and check Supabase — all without leaving the IDE.
Configuration in Cursor
In Cursor, go toSettings → Features → MCP and click "Add new MCP server". You can also directly edit ~/.cursor/mcp.json:
{
"mcpServers": {
"supabase": {
"command": "npx",
"args": ["-y", "@supabase/mcp-server-supabase@latest",
"--supabase-url", "https://xxx.supabase.co",
"--supabase-service-role-key", "eyJ..."]
}
}
}
MCP config files sometimes contain sensitive keys. Add mcp.json to.gitignore, or use environment variables (env vars) for secrets.
MCP servers worth knowing
Development and DevTools
| Server | What it does | Open source |
|---|---|---|
| GitHub | Repos, Issues, PRs, Code Search | Yes |
| GitLab | Managing GitLab repos and pipelines | Yes |
| Supabase | DB, Auth, Storage, Edge Functions | Yes |
| Playwright | Browser automation and testing | Yes |
| Docker | Managing containers and images | Yes |
| Sentry | Analyzing errors and stack traces | Yes |
Management and operations
| Server | Use |
|---|---|
| Slack | Reading and sending messages, managing channels |
| Notion | Reading/writing to Notion databases and pages |
| Google Drive | Access to files, Docs, Sheets and Slides |
| Linear | Managing issues, projects and sprints |
| Jira | Atlassian tickets, epics, workflows |
| Stripe | Managing payments, customers and subscriptions |
The official list is atgithub.com/modelcontextprotocol/servers. In addition, the sites mcp.so and glama.ai/mcp/servers collect thousands of community servers with search and ranking.
Building your own MCP server
Building an MCP server is surprisingly simple. Anthropic provides an SDK for Python and TypeScript. In 30 lines of code you can create a server that exposes tools to Claude.
A basic server in Python (FastMCP)
from mcp.server.fastmcp import FastMCP
mcp = FastMCP("my-server")
@mcp.tool()
def get_weather(city: str) -> str:
"""Get the weather forecast for a city"""
# in practice — a call to an API
return f"The weather in {city}: 25°C, partly cloudy"
@mcp.tool()
def calculate(expression: str) -> float:
"""Evaluate a math expression"""
return eval(expression) # for example only!
@mcp.resource("docs://readme")
def get_readme() -> str:
"""Read the project's README"""
with open("README.md") as f:
return f.read()
if __name__ == "__main__":
mcp.run() # stdio transport by default
A server in TypeScript
import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
import { z } from "zod";
const server = new McpServer({ name: "my-server", version: "1.0.0" });
server.tool(
"search_database",
{ query: z.string(), limit: z.number().optional() },
async ({ query, limit = 10 }) => {
// an actual DB call
const results = await db.search(query, limit);
return {
content: [{ type: "text", text: JSON.stringify(results) }]
};
}
);
const transport = new StdioServerTransport();
await server.connect(transport);
Connecting the server you built to Claude Desktop
{
"mcpServers": {
"my-server": {
"command": "python",
"args": ["/path/to/my_server.py"]
}
}
}
Examples from the field — what people build with MCP
MCP is a cornerstone of Agentic AI. When you combine MCP with AI Agents that operate over time, you get agents that can access external tools, remember information between sessions and act across the organization's network of APIs. This is the future of business automation.
MCP isn't just a technical tool — it's a paradigm shift. AI moves from a "conversation assistant" to an "active player" connected to your environment. The moment you connect Claude to the tools you work with every day, you'll understand why it's the most important thing that happened in AI in 2025.