cidx.dev logo
← Back to Resources
If you haven't set up the terminal application, go here first.

How to set up the Code Index MCP on CursorAI

Follow these steps to integrate the Code Index MCP with CursorAI and unlock powerful documentation, code search, and agent features directly in your IDE.

Last Updated: May 13, 2025

  1. Open Cursor settings
    Open Cursor settings
  2. Navigate to the MCP server section
    Open MCP section inside settings
  3. Click + Add new global MCP server
  4. You should see an empty MCP servers configuration like this:
    Empty MCP servers configuration
  5. Add the Code Index MCP server to the JSON configuration. You can copy and paste this example:
    {
      "mcpServers": {    
        "cidx-mcp": {
          "command": "cidx",
          "args": [
            "--mcp"
          ]
        }
      }
    }
    Code Index MCP JSON inside settings
    Note: If you already have other MCP servers installed, you only need to add this portion inside your mcpServers object:
      "cidx-mcp": {
        "command": "cidx",
        "args": [
          "--mcp"
        ]
      }
    Example with another server:
    {
      "mcpServers": {
        "cidx-mcp": {
          "command": "cidx",
          "args": ["--mcp"]
        },
        "dummy-server": {
          "command": "dummy",
          "args": ["--mcp"]
        }
      }
    }
  6. When fully installed, it should look like this (note the green light next to cidx-mcp):
    Code Index fully installed in Cursor MCP settings view

You can now close the Cursor settings and start coding!

Try some example commands in CursorAI (be sure to mention mcp in your prompt):

Create a 3D game that makes use of Threejs and Rapier, please consult with the code index mcp
Setup OAUTH authentication with GitHub and be sure to look up the mcp for the right documentation.
Please fix this bug attatched and look up the mcp documentation to speed up the fix

For more help, visit our Resources page or contact support.