What Is an MCP Client? How Claude, Cursor, and VS Code Connect to MCP Servers
An MCP client is the AI application side — Claude, Cursor, VS Code Copilot. It discovers MCP servers, decides when to call tools, and processes responses. Here is how each one works.
An MCP client is the AI application that connects to MCP servers. It discovers available tools, decides when to call them, and processes the results. If you have set up an MCP server before, you were configuring the client side without necessarily thinking about it — every time you edited claude_desktop_config.json or ran claude mcp add, you were telling an MCP client how to reach a server.
This article explains what MCP clients do, how they work internally, and how every major client differs in setup and capability.
MCP Client vs MCP Server: The Core Distinction
The Model Context Protocol defines three roles:
- Host — The AI application you interact with (Claude Desktop, Cursor, VS Code).
- Client — A connector inside the host that manages the connection to one MCP server. A host can run many clients simultaneously.
- Server — The program that exposes tools, resources, and prompts.
The server is passive. It waits for requests and responds. The client is active. It initiates connections, discovers what the server offers, decides which tools to invoke based on your conversation, sends the call, and routes the response back to the AI model.
Analogy: The server is a restaurant kitchen. The client is the waiter — it knows the menu, takes your order, relays it to the kitchen, and brings back the dish. You (the user) never interact with the kitchen directly.
In practice, "MCP client" and "host" are often used interchangeably. When someone says "Claude Desktop is an MCP client," they mean the host application contains one or more MCP client instances.
How an MCP Client Works
Every MCP client follows the same four-step cycle:
1. Discovery
When the client starts (or when you add a new server), it connects to the MCP server and calls tools/list. The server responds with a JSON array describing every tool it offers — name, description, input schema. The client now knows what the server can do.
For resources and prompts, the client calls resources/list and prompts/list respectively.
2. Selection
When you send a message, the AI model sees the tool descriptions alongside your prompt. It decides whether any tool would help answer your question. This is the model's reasoning — not hardcoded logic. The model might call zero tools, one tool, or chain several in sequence.
3. Invocation
The client sends a tools/call request to the appropriate server with the tool name and arguments. For a local server, this goes over stdin/stdout. For a remote server, it goes over Streamable HTTP with a Bearer token.
4. Response Processing
The server returns structured data. The client passes it back to the AI model as context. The model incorporates the result into its response to you. The entire cycle — discovery, selection, invocation, response — can repeat multiple times within a single conversation turn.
Transport: How Clients Talk to Servers
MCP clients support two transport mechanisms:
stdio (local) — The client spawns the server as a subprocess and communicates via standard input/output. No network, no authentication. This is the default for desktop setups and the simplest to configure.
Streamable HTTP (remote) — The client connects to the server over HTTPS. Supports streaming via server-sent events when needed. Requires authentication, typically OAuth 2.1 with PKCE. This is the transport for team-shared servers, cloud-hosted servers, and mobile/web clients that cannot spawn local processes.
The older SSE (Server-Sent Events) transport from the original November 2024 spec is deprecated. If you see tutorials referencing SSE, they predate the March 2025 spec update.
Authentication for remote servers: When a client connects to a remote server without a token, the server responds with HTTP 401 and a WWW-Authenticate header pointing to its authorization server. The client then runs a standard OAuth 2.1 flow — authorization code with PKCE — to obtain a Bearer token. Every subsequent request includes that token.
Every Major MCP Client
Claude Desktop
Anthropic's reference MCP client. The first application to support MCP (November 2024) and still the most complete implementation.
Config file: ~/Library/Application Support/Claude/claude_desktop_config.json (macOS)
{
"mcpServers": {
"toolradar": {
"command": "npx",
"args": ["-y", "toolradar-mcp"],
"env": {
"TOOLRADAR_API_KEY": "tr_live_your_key"
}
}
}
}
Restart required after config changes. Supports stdio and Streamable HTTP. Has a tool approval UI — you confirm each tool call before execution. Supports Desktop Extensions (.mcpb) for one-click server installation.
Setup guide: How to Set Up MCP Servers in Claude Desktop
Claude Code
Anthropic's terminal-based AI agent. The most powerful MCP client available — it supports three scope levels, acts as both client and server, and lazy-loads tools via Tool Search.
Config command:
claude mcp add toolradar --scope user -- npx -y toolradar-mcp
Three scope levels:
--scope user— Global, all projects (GitHub, Brave Search, Toolradar)--scope local— Per-user, per-project (default)--scope project— Writes to.mcp.jsonin the project root, shared via git
No restart needed. Supports stdio and Streamable HTTP. No approval UI — tools execute automatically (use --scope carefully).
Best servers: Best MCP Servers for Claude Code
ChatGPT
OpenAI added MCP support in September 2025 through Developer Mode (renamed to "Apps" in December 2025). Available on Plus, Pro, Team, Business, Enterprise, and Edu plans.
Setup: Settings > Connectors > Create. Provide a name, description, and MCP server URL. Authentication is OAuth 2.1 — ChatGPT handles the flow automatically.
Key difference: ChatGPT only supports remote MCP servers over Streamable HTTP. No local stdio servers. Every server must be deployed to a public URL with OAuth. This makes setup harder but eliminates the security surface of local process spawning.
ChatGPT displays explicit confirmation modals before any write/modify operation.
Cursor
The most popular IDE-based MCP client. Supports both project-level and global configuration.
Config file: .cursor/mcp.json (project) or ~/.cursor/mcp.json (global)
{
"mcpServers": {
"toolradar": {
"command": "npx",
"args": ["-y", "toolradar-mcp"],
"env": {
"TOOLRADAR_API_KEY": "tr_live_your_key"
}
}
}
}
No restart needed — Cursor picks up config changes automatically. Also supports remote servers with url and headers fields. MCP tools are available in Composer (Agent mode) and Cmd+K.
Best servers: Best MCP Servers for Cursor
VS Code + GitHub Copilot
GitHub Copilot in VS Code reached GA with MCP support in mid-2025. Configuration lives in .vscode/mcp.json (workspace) or your user-level mcp.json.
Config file: .vscode/mcp.json
{
"servers": {
"toolradar": {
"command": "npx",
"args": ["-y", "toolradar-mcp"],
"env": {
"TOOLRADAR_API_KEY": "tr_live_your_key"
}
}
}
}
Note the key difference: VS Code uses "servers" instead of "mcpServers". VS Code provides IntelliSense for the config file and supports both stdio and Streamable HTTP. If you already have a Claude Desktop config, VS Code can import it via settings.json.
Windsurf
Codeium's AI IDE with full MCP support.
Config file: ~/.codeium/windsurf/mcp_config.json
{
"mcpServers": {
"toolradar": {
"command": "npx",
"args": ["-y", "toolradar-mcp"],
"env": {
"TOOLRADAR_API_KEY": "tr_live_your_key"
}
}
}
}
Access from the Cascade panel > MCPs icon > Configure. Supports environment variable interpolation in all fields.
Zed
The first third-party editor to ship MCP support (late 2024). Configuration is in Zed's settings file under the "context_servers" key.
Cline
VS Code extension for autonomous AI coding. MCP config at ~/.cline/mcp_config.json using the standard mcpServers format. Cline grants tools broad autonomy by default — review permissions carefully.
Continue.dev
Open-source AI code assistant for VS Code and JetBrains. Supports MCP via ~/.continue/mcp.json or inline in config.yaml. Can import Claude Desktop config files directly by dropping them into .continue/mcpServers/.
Replit
Cloud-based IDE with MCP support added late 2025. Configured through the Replit UI — no local config files since everything runs in the cloud.
JetBrains IDEs
IntelliJ IDEA, WebStorm, PyCharm, and others support MCP via plugin. Configured through the IDE settings UI.
Client Comparison Table
| Client | Transport | Config Format | Auto-Reload | Tool Approval | Desktop Extensions |
|---|---|---|---|---|---|
| Claude Desktop | stdio, HTTP | claude_desktop_config.json | No (restart) | Yes | Yes (.mcpb) |
| Claude Code | stdio, HTTP | claude mcp add / .mcp.json | Yes | No | Yes (.mcpb) |
| ChatGPT | HTTP only | UI (Settings > Apps) | N/A | Yes (write ops) | No |
| Cursor | stdio, HTTP | .cursor/mcp.json | Yes | Configurable | No |
| VS Code | stdio, HTTP | .vscode/mcp.json | Yes | Yes | No |
| Windsurf | stdio, HTTP | ~/.codeium/windsurf/mcp_config.json | Yes | Configurable | No |
| Cline | stdio, HTTP | ~/.cline/mcp_config.json | Yes | Configurable | No |
| Continue.dev | stdio, HTTP | ~/.continue/mcp.json | Yes | Configurable | No |
Tool Search: How Claude Code Reduces Context Bloat
Most MCP clients load every tool definition from every connected server into the model's context window at the start of each conversation. Connect five servers exposing 200 tools total, and you lose tens of thousands of tokens before typing anything. One developer measured 66,000 tokens consumed by tool definitions alone — a third of Sonnet 4.5's 200K context window.
Claude Code solves this with Tool Search, a lazy-loading system introduced in version 2.1.7.
How it works: Instead of injecting all tool schemas upfront, Claude Code builds a lightweight search index of tool names and descriptions. When the model needs a tool, it searches the index, and only then loads the full schema for that specific tool. The rest stay out of context.
When it activates: Automatically, when your connected MCP tools would consume more than 10% of available context. No configuration needed.
Impact: Internal benchmarks show Tool Search improved accuracy on MCP evaluations from 49% to 74% for Opus 4, and from 79.5% to 88.1% for Opus 4.5. Context savings reach roughly 85-95% compared to upfront loading.
This is why Claude Code can handle 10+ connected MCP servers without degradation, while other clients struggle with more than three or four.
Desktop Extensions: One-Click Installation
Desktop Extensions (.mcpb files) are the equivalent of browser extensions for MCP clients. Instead of editing JSON config files and running terminal commands, you download a .mcpb file, double-click it, and the MCP server is installed and configured automatically.
A .mcpb file is a zip archive containing:
- A
manifest.jsondescribing the server, its capabilities, and requirements - The server code itself (typically a Node.js package)
The format was originally called DXT (.dxt) and was renamed to MCP Bundle (.mcpb) in late 2025 as part of donating MCP to the Agentic AI Foundation under the Linux Foundation.
Current support: Claude Desktop and Claude Code support .mcpb natively. Other clients (Cursor, VS Code, Windsurf) do not support the format yet — they rely on JSON configuration or their own UI workflows instead.
Why it matters: MCP's biggest adoption barrier is configuration friction. Desktop Extensions reduce installation to a single click, which is how browser extensions, VS Code extensions, and mobile apps already work. As more clients adopt the format, expect the MCP ecosystem to look more like an app store.
Claude Code as Both Client AND Server
Claude Code is unique in the MCP ecosystem: it can act as a client (consuming MCP servers you configure) and a server (exposing its own tools to other clients) simultaneously.
Run claude mcp serve and Claude Code becomes an MCP server that other applications — Claude Desktop, Cursor, Windsurf — can connect to. The exposed tools include Bash, Read, Write, Edit, Glob, and Grep.
This enables architectures where a "manager" AI delegates work to Claude Code running headless. An agent in Claude Desktop could ask Claude Code to refactor a codebase, run tests, and report results — all through MCP.
Security note: Each client connection gets a fresh Claude Code instance. Communication happens via stdio (process pipes), so there is no network exposure. Connected clients access only Claude Code's own tools — they cannot reach MCP servers that Claude Code itself is connected to.
Building Your Own MCP Client
If you are building an AI application and want it to consume MCP servers, the official SDKs handle the protocol:
- TypeScript:
@modelcontextprotocol/sdk— runs on Node.js, Bun, and Deno. Includes client classes, transport helpers, and OAuth utilities. - Python:
mcppackage — full spec implementation with async support.
Both SDKs handle transport negotiation, tool discovery, and the JSON-RPC 2.0 message format. A minimal client connects to a server, calls tools/list, and then routes tools/call requests based on model output.
The official tutorial walks through building an LLM-powered chatbot that connects to any MCP server in roughly 100 lines of code.
Key architectural decision: Each MCP client instance maintains a 1:1 connection with a single server. If your application needs to connect to multiple servers, you create multiple client instances — one per server — and aggregate their tool lists before presenting them to the model.
What to Do Next
If you have been using MCP servers but never thought about the client side, you now understand what is happening under the hood. The client is doing the heavy lifting — discovery, selection, invocation, response routing — while the server just answers requests.
Pick your client based on your workflow:
- Building software? Claude Code (most powerful, Tool Search, dual client/server) or Cursor (best IDE integration)
- General productivity? Claude Desktop (simplest setup, tool approval UI) or ChatGPT (remote only, broadest user base)
- Team standardization? VS Code + Copilot (Settings Sync, workspace configs in git)
Then add servers:
- Best MCP Servers in 2026 — 25 top picks across every category
- Best MCP Servers for Claude Code — 10 servers with exact setup commands
- Best MCP Servers for Cursor — 12 servers optimized for IDE workflows
Want your AI to search 8,400+ software tools with verified pricing and real editorial scores? Set up Toolradar MCP -->
Related Articles
MCP Server Authentication: OAuth 2.1, API Keys, and Security Best Practices
MCP Server Authentication: OAuth 2.1, API Keys, and Security Best Practices
How to authenticate MCP servers — env vars for local, OAuth 2.1 for remote. Covers PKCE, client-credentials, and the CVE that broke mcp-remote.
Best MCP Servers for Marketing Teams: HubSpot, Salesforce, Ahrefs, and More
Best MCP Servers for Marketing Teams: HubSpot, Salesforce, Ahrefs, and More
MCP servers for marketers — CRM, SEO, email, analytics. Setup guides for HubSpot, Salesforce, Ahrefs, and more.
Streamable HTTP vs SSE: Why MCP Changed Transports (And How to Migrate)
Streamable HTTP vs SSE: Why MCP Changed Transports (And How to Migrate)
MCP introduced Streamable HTTP in March 2025, replacing SSE. With SSE deprecation approaching, here is what changed and how to migrate.