How to Set Up MCP in Cursor IDE
The complete 2026 guide to adding Model Context Protocol servers to Cursor for AI-powered coding
What is MCP and Why Use It with Cursor?
The Model Context Protocol (MCP) is an open standard that lets AI coding assistants connect to external tools, databases, and APIs. When you add MCP servers to Cursor, your AI assistant can query databases, manage GitHub repos, search the web, and interact with dozens of services — all without leaving your editor.
Cursor has supported MCP since early 2025, and as of 2026 it's one of the most popular MCP clients alongside Claude Code and Windsurf. Here's how to get started.
Step 1: Open Cursor MCP Settings
In Cursor, MCP configuration lives in your project's .cursor/mcp.json file or global settings.
Option A: Project-level config
// .cursor/mcp.json
{
"mcpServers": {
"github": {
"command": "npx",
"args": ["@modelcontextprotocol/server-github"],
"env": {
"GITHUB_TOKEN": "ghp_your_token_here"
}
}
}
}Option B: Global config
Go to Cursor Settings → Features → MCP to add servers that persist across all projects.
Step 2: Add Popular MCP Servers
Here are the most popular MCP servers developers use with Cursor:
npx @modelcontextprotocol/server-githubnpx @modelcontextprotocol/server-postgres postgresql://localhost:5432/mydbnpx supabase-mcp-servernpx @modelcontextprotocol/server-brave-searchnpx @modelcontextprotocol/server-filesystem /path/to/projectStep 3: Verify Your MCP Servers
After adding servers, restart Cursor. You should see green indicators next to each MCP server in your settings. If a server shows red, check:
- Node.js 18+ is installed (required for npx servers)
- Environment variables are set correctly
- The server package exists on npm
- Your firewall isn't blocking connections
Common Issues and Fixes
What Can You Do With MCP in Cursor?
Once configured, simply chat with Cursor's AI and it will automatically use MCP tools when relevant:
"Query the users table and show me the schema" → Uses PostgreSQL MCP
"Create a new GitHub issue for this bug" → Uses GitHub MCP
"Search for the latest Next.js deployment best practices" → Uses Brave Search MCP
"Read the README in the docs folder" → Uses Filesystem MCP
Browse All MCP Servers for Cursor
Find the perfect MCP servers for your Cursor IDE workflow