Model Context Protocol (MCP)
The Model Context Protocol (MCP) is a standard for connecting Large Language Models (LLMs) to external services. This guide provides detailed setup instructions for several popular AI development tools, with in-depth coverage for Claude, Cursor, and Windsurf.
What is MCP?
MCP enables seamless communication between different AI models and your development environment, allowing for enhanced functionality and integration capabilities.
Prerequisites
- Your preferred AI development tool (Cursor, Claude, Windsurf, etc)
- Basic understanding of JSON configuration files
While MCP supports many tools, this guide provides detailed setup instructions for select popular clients. For other tools, please refer to their respective documentation.
Supported Clients
MCP is supported by a growing ecosystem of AI development tools and platforms, including IDEs, AI assistants, and development frameworks.
For a complete and up-to-date list of supported clients, visit:
Setting Up Claude
Step 1: Access Settings
Open Claude desktop and navigate to Settings > Developer.
Step 2: Configure MCP
Click "Edit Config" and add the following configuration:
{
"mcpServers": {
"file-system": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-script"]
}
}
}
Step 3: Restart Claude
Restart Claude desktop to apply the new configuration. You should see a hammer (MCP) icon appear with the new MCP server available.
Setting Up Cursor
Step 1: Create Configuration Directory
Create a .cursor
directory in your project root if it doesn't exist.
Step 2: Create Configuration File
Create a .cursor/mcp.json
file with the following configuration:
{
"mcpServers": {
"file-system": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-script"]
}
}
}
Step 3: Verify Configuration
Open Cursor and navigate to Settings/MCP. You should see a green active status after the server is successfully connected.
Setting Up Windsurf
Step 1: Access Settings
Navigate to Windsurf - Settings > Advanced Settings or use Command Palette > Open Windsurf Settings Page.
Step 2: Add MCP Server
Scroll down to the Cascade section. You'll find options to:
- Add a new server
- View existing servers
- View the raw JSON config file at
mcp_config.json
Click the "Add Server" button to choose from pre-populated servers, or click "Add custom server +" to add your own server directly in mcp_config.json
.
Step 3: Configure MCP
If adding a custom server, edit ~/.codeium/windsurf/mcp_config.json
with your configuration:
{
"mcpServers": {
"file-system": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-script"]
}
}
}
Step 4: Refresh Configuration
After adding a new MCP server, make sure to press the refresh button to apply the changes.
Important Notes
- MCP tool calls will consume credits regardless of success or failure
- Only tools are supported (not prompts or resources)
- Tools that output images are not supported
- Only servers using the
stdio
transport type are supported