MCP Directory

How to add AiDex to Cursor

Persistent code index + memory, semantic search & live telemetry for AI coding agents — 50x less context than grep. Paste the config into ~/.cursor/mcp.json and restart Cursor.

Last updated June 14, 2026 · 37 · stdio · no auth

Cursor config for AiDex

npm install -g aidex-mcp
{
  "mcpServers": {
    "aidex": {
      "command": "aidex",
      "args": []
    }
  }
}

Setup steps

  1. 1Open Cursor → Settings → MCP → Add new MCP server (or edit ~/.cursor/mcp.json directly).
  2. 2Paste the AiDex config below into the "mcpServers" object.
  3. 3Fill in placeholder secrets, then save.
  4. 4Cursor reloads MCP servers automatically — check Settings → MCP for a green status dot.
  5. 5Ask Cursor to use one of AiDex's tools to confirm it's connected.

Before you start

  • Node.js >= 18
  • An MCP-compatible client (Claude Code, Claude Desktop, Cursor, Windsurf, Gemini CLI, or VS Code Copilot)
  • Optional: an LLM API key (Anthropic / OpenAI / OpenRouter / Ollama / HuggingFace) only if you enable the optional LLM reranking/translation layer

What AiDex can do in Cursor

aidex_init

Index a project (creates .aidex/); pass embeddings:true to enable semantic search.

aidex_query

Search identifiers by term with mode exact/contains/starts_with and optional time filtering.

aidex_search

Hybrid / semantic / exact retrieval over embedded code, docs and workspace items.

aidex_settings

Configure embeddings, LLM provider/model and the llm_send_code privacy switch (Settings tab in Viewer).

aidex_signature

Get the classes + methods of a single file without reading it.

aidex_signatures

Get signatures for multiple files via a glob pattern.

aidex_update

Re-index a single changed file (incremental).

aidex_remove

Remove a deleted file from the index.

Security

Local-first: works fully offline with pure embeddings; the index lives in your project at .aidex/index.db (SQLite). The optional LLM layer (Anthropic / OpenAI / OpenRouter / Ollama / HuggingFace) is opt-in and requires an API key configured in Settings — never required for the MCP connection itself. Privacy switch `llm_send_code` defaults to OFF, so only your literal query and metadata (paths, names, anchors) are sent to the LLM; code bodies stay local. Auto-setup (run on `npm install -g`) detects installed AI clients and registers AiDex, and writes usage instructions into client config files (e.g. ~/.claude/CLAUDE.md); skip it with AIDEX_NO_SETUP=1. The Log Hub / Debug Dashboard / Viewer open local HTTP servers (ports 3333/3334/3335) that accept unauthenticated POSTs from any local program.

AiDex + Cursor FAQ

Where is the Cursor config file?

Cursor reads MCP servers from ~/.cursor/mcp.json. Paste the AiDex config there under the "mcpServers" key and restart the client.

Is AiDex safe to use with Cursor?

Local-first: works fully offline with pure embeddings; the index lives in your project at .aidex/index.db (SQLite). The optional LLM layer (Anthropic / OpenAI / OpenRouter / Ollama / HuggingFace) is opt-in and requires an API key configured in Settings — never required for the MCP connection itself. Privacy switch `llm_send_code` defaults to OFF, so only your literal query and metadata (paths, names, anchors) are sent to the LLM; code bodies stay local. Auto-setup (run on `npm install -g`) detects installed AI clients and registers AiDex, and writes usage instructions into client config files (e.g. ~/.claude/CLAUDE.md); skip it with AIDEX_NO_SETUP=1. The Log Hub / Debug Dashboard / Viewer open local HTTP servers (ports 3333/3334/3335) that accept unauthenticated POSTs from any local program.

Does AiDex require an LLM API key or send my code to the cloud?

No. It is local-first and works fully offline with pure local embeddings. The LLM layer (Anthropic / OpenAI / OpenRouter / Ollama / HuggingFace) is opt-in. Even when enabled, the llm_send_code privacy switch defaults to OFF, so only your literal query and metadata are sent — code bodies stay local.

Which AI clients and languages are supported?

Any MCP-compatible client, with documented setup for Claude Code, Claude Desktop, Cursor, Windsurf, Gemini CLI and VS Code Copilot. It parses 12 languages: C#, TypeScript, JavaScript, Rust, Python, C, C++, Java, Go, PHP, Ruby and HCL/Terraform.

Where is the index stored and does it persist between sessions?

Each project keeps its own .aidex/index.db (SQLite with WAL mode) as the single source of truth; a global registry lives at ~/.aidex/global.db. The index persists indefinitely and survives sessions, with incremental single-file updates after changes.

View repo Full AiDex page