Connect external tools and data sources to Cursor using MCP
Model Context Protocol (MCP) is a protocol for connecting Cursor to external tools and data sources.
MCP connects Cursor to external systems and data. Instead of explaining your project structure repeatedly, integrate directly with your tools.
Write MCP servers in any language that can print to stdout
or serve an HTTP endpoint - Python, JavaScript, Go, etc.
MCP servers expose capabilities through the protocol, connecting Cursor to external tools or data sources.
Cursor supports three transport methods:
Transport | Execution environment | Deployment | Users | Input | Auth |
---|---|---|---|---|---|
stdio | Local | Cursor manages | Single user | Shell command | Manual |
SSE | Local/Remote | Deploy as server | Multiple users | URL to an SSE endpoint | OAuth |
Streamable HTTP | Local/Remote | Deploy as server | Multiple users | URL to an HTTP endpoint | OAuth |
Install MCP servers from our collection and authenticate with OAuth.
mcp.json
Configure custom MCP servers with a JSON file:
Create .cursor/mcp.json
in your project for project-specific tools.
Create ~/.cursor/mcp.json
in your home directory for tools available everywhere.
MCP servers use environment variables for authentication. Pass API keys and tokens through the config.
Cursor supports OAuth for servers that require it.
The Composer Agent automatically uses MCP tools listed under Available Tools
when relevant. Ask for a specific tool by name or describe what you need. Enable or disable tools from settings.
Enable or disable MCP tools directly from the chat interface. Click a tool name in the tools list to toggle it. Disabled tools won’t be loaded into context or available to Agent.
Agent asks for approval before using MCP tools by default. Click the arrow next to the tool name to see arguments.
Enable auto-run for Agent to use MCP tools without asking. Works like terminal commands. Read more about Yolo mode here.
Cursor shows the response in chat with expandable views of arguments and responses:
MCP servers can return images - screenshots, diagrams, etc. Return them as base64 encoded strings:
See this example server for implementation details. Cursor attaches returned images to the chat. If the model supports images, it analyzes them.
When installing MCP servers, consider these security practices:
Remember that MCP servers can access external services and execute code on your behalf. Always understand what a server does before installation.
For practical examples of MCP in action, see our Web Development guide which demonstrates integrating Linear, Figma, and browser tools into your development workflow.
What's the point of MCP servers?
MCP servers connect Cursor to external tools like Google Drive, Notion, and other services to bring docs and requirements into your coding workflow.
How do I debug MCP server issues?
View MCP logs by:
The logs show server initialization, tool calls, and error messages.
Can I temporarily disable an MCP server?
Yes! Toggle servers on/off without removing them:
Disabled servers won’t load or appear in chat. This is useful for troubleshooting or reducing tool clutter.
What happens if an MCP server crashes or times out?
If an MCP server fails:
Cursor isolates server failures to prevent one server from affecting others.
How do I update an MCP server?
For npm-based servers:
npm cache clean --force
For custom servers, update your local files and restart Cursor.
Can I use MCP servers with sensitive data?
Yes, but follow security best practices:
stdio
transportConnect external tools and data sources to Cursor using MCP
Model Context Protocol (MCP) is a protocol for connecting Cursor to external tools and data sources.
MCP connects Cursor to external systems and data. Instead of explaining your project structure repeatedly, integrate directly with your tools.
Write MCP servers in any language that can print to stdout
or serve an HTTP endpoint - Python, JavaScript, Go, etc.
MCP servers expose capabilities through the protocol, connecting Cursor to external tools or data sources.
Cursor supports three transport methods:
Transport | Execution environment | Deployment | Users | Input | Auth |
---|---|---|---|---|---|
stdio | Local | Cursor manages | Single user | Shell command | Manual |
SSE | Local/Remote | Deploy as server | Multiple users | URL to an SSE endpoint | OAuth |
Streamable HTTP | Local/Remote | Deploy as server | Multiple users | URL to an HTTP endpoint | OAuth |
Install MCP servers from our collection and authenticate with OAuth.
mcp.json
Configure custom MCP servers with a JSON file:
Create .cursor/mcp.json
in your project for project-specific tools.
Create ~/.cursor/mcp.json
in your home directory for tools available everywhere.
MCP servers use environment variables for authentication. Pass API keys and tokens through the config.
Cursor supports OAuth for servers that require it.
The Composer Agent automatically uses MCP tools listed under Available Tools
when relevant. Ask for a specific tool by name or describe what you need. Enable or disable tools from settings.
Enable or disable MCP tools directly from the chat interface. Click a tool name in the tools list to toggle it. Disabled tools won’t be loaded into context or available to Agent.
Agent asks for approval before using MCP tools by default. Click the arrow next to the tool name to see arguments.
Enable auto-run for Agent to use MCP tools without asking. Works like terminal commands. Read more about Yolo mode here.
Cursor shows the response in chat with expandable views of arguments and responses:
MCP servers can return images - screenshots, diagrams, etc. Return them as base64 encoded strings:
See this example server for implementation details. Cursor attaches returned images to the chat. If the model supports images, it analyzes them.
When installing MCP servers, consider these security practices:
Remember that MCP servers can access external services and execute code on your behalf. Always understand what a server does before installation.
For practical examples of MCP in action, see our Web Development guide which demonstrates integrating Linear, Figma, and browser tools into your development workflow.
What's the point of MCP servers?
MCP servers connect Cursor to external tools like Google Drive, Notion, and other services to bring docs and requirements into your coding workflow.
How do I debug MCP server issues?
View MCP logs by:
The logs show server initialization, tool calls, and error messages.
Can I temporarily disable an MCP server?
Yes! Toggle servers on/off without removing them:
Disabled servers won’t load or appear in chat. This is useful for troubleshooting or reducing tool clutter.
What happens if an MCP server crashes or times out?
If an MCP server fails:
Cursor isolates server failures to prevent one server from affecting others.
How do I update an MCP server?
For npm-based servers:
npm cache clean --force
For custom servers, update your local files and restart Cursor.
Can I use MCP servers with sensitive data?
Yes, but follow security best practices:
stdio
transport