Skip to content
Technical Architecture Documentation

Cursor IDE MCP Integration & Workspace Rules Guide

Complete reference for setting up Model Context Protocol servers in Cursor IDE, configuring workspace-level .cursor/mcp.json files, and leveraging MCP tools in Agent Composer loops.

1. Native MCP Integration in Cursor IDE

Cursor IDE features deep native integration with Model Context Protocol. MCP tools registered in Cursor automatically surface to Cursor Agent Composer, allowing AI coding models to execute shell commands, inspect databases, and query external APIs during chat interactions.

2. Global vs Project-Specific Configuration (.cursor/mcp.json)

Global configuration applies across all workspace projects opened in Cursor. Project-specific configuration lives inside `.cursor/mcp.json` at the root of your repository and can be checked into version control (excluding secret API keys).

{
  "mcpServers": {
    "supabase-mcp": {
      "command": "npx",
      "args": ["-y", "@mcp/server-supabase"],
      "env": {
        "SUPABASE_URL": "https://xyz.supabase.co",
        "SUPABASE_SERVICE_ROLE_KEY": "YOUR_SERVICE_ROLE_KEY"
      }
    }
  }
}

3. Invoking MCP Tools in Cursor Composer Prompts

Once registered, tools are automatically available in Cursor Agent Composer. You can prompt the assistant naturally, e.g.:

"@Composer Query Supabase database schema for table 'users', retrieve the top 5 records, and generate a TypeScript interface."