Overview
Connect CodeAlive with Cursor IDE to enhance your AI-powered development experience. CodeAlive provides Cursor with deep contextual understanding of your entire codebase through the Model Context Protocol (MCP).Cursor ships its own
codebase_search and will prefer it by default. Connecting the MCP server is not enough — add a project rule so Cursor’s agent reaches for CodeAlive first. See CodeAlive vs Cursor’s built-in codebase search and the ready-made rule in Project Rules.Working with 1C:Enterprise (BSL)? Also read CodeAlive & 1С — the term “metadata” needs explicit disambiguation in 1C projects.
Prerequisites
- Cursor installed (latest version recommended)
- CodeAlive account (Sign up here)
- Indexed repositories in your CodeAlive dashboard
Connecting to CodeAlive
1
Open MCP settings
Open Cursor Settings:
- macOS:
Cmd+,or menu Cursor → Settings - Windows/Linux:
Ctrl+,or File → Preferences → Settings
In older Cursor builds this panel was named Tools & Integrations.
2
Add the CodeAlive server
Cursor opens Save the file.
.cursor/mcp.json (project-level) or ~/.cursor/mcp.json (global) for editing. Paste this configuration:Cursor detects the transport from the
url field — Streamable HTTP first, with automatic SSE fallback.Cursor supports OAuth for remote Streamable HTTP servers. Follow the browser sign-in prompt; in Cursor Agent you can start it explicitly with
cursor-agent mcp login codealive.3
Verify the connection
Back on Tools & MCP, authenticate when prompted. The
codealive server should then show a green status dot.4
Try it in chat
Open Cursor’s chat panel and try:
- “What repositories are available in CodeAlive?”
- “Search for authentication logic in my codebase”
- “Explain the architecture of my project”
One-Click Install Link
Cursor supports a deeplink that installs an MCP server in one click. Encode the CodeAlive config as base64 JSON and open this URL:BASE64_CONFIG from this JSON:
CodeAlive vs Cursor’s built-in codebase search
Cursor’s agent has a nativecodebase_search tool backed by a local index of the open workspace. It cannot be disabled in the default Agent mode (tool selection is only available in Custom Modes, and the built-in search has known quirks there), and without instructions the planner will use it for every exploration question — your connected CodeAlive server never gets called.
The two tools are not equivalent:
Since you cannot remove the built-in tool, the working approach is a precedence rule that names it explicitly. Vague phrasing (“prefer CodeAlive for search”) reliably loses to the planner’s default; naming
codebase_search as the thing to avoid wins. That is what the rule below does.
Project Rules for CodeAlive
Project rules teach Cursor’s agent how to use CodeAlive. The legacy.cursorrules file is deprecated — use .cursor/rules/*.mdc (MDC format) instead.
Cursor rules have four activation modes, controlled by the .mdc frontmatter:
For a tool-precedence rule use Always — it must be active before the planner picks its first search tool, so an on-demand mode is too late. Keep it short for that same reason: always-on rules are injected into every request.
Create
.cursor/rules/codealive.mdc in your project:
See Instructing Coding Agents for the general patterns behind this rule (imperative + trigger, naming the built-in tool, sequencing) and a universal
AGENTS.md variant that also covers teammates on other agents — Cursor’s CLI reads repo-root AGENTS.md too. Cursor rules reference: cursor.com/docs/context/rules.Usage Patterns
- Smart Completion
- Intelligent Refactoring
- Context-Aware Debugging
Advanced Features
Multi-File Operations
Cursor can use CodeAlive to work across multiple files:Find Dependencies
Find Dependencies
Impact Analysis
Impact Analysis
Pattern Matching
Pattern Matching
Project vs Global Configuration
Cursor reads MCP servers from two locations:- Project-level:
.cursor/mcp.jsonat the workspace root — commit this so the whole team gets the server. - Global:
~/.cursor/mcp.json— applies to every project on your machine.
Team Collaboration
Share the project-level config without exposing API keys:- Commit
.cursor/mcp.jsonreferencing an environment variable:
- Each teammate exports their own key before launching Cursor:
Docker Alternative
Run the CodeAlive MCP server locally with Docker (stdio transport):Productivity Tips
Slash Commands
Save recurring CodeAlive prompts as slash commands in
.cursor/commands for one-tap reuse.Beyond Context Windows
Use CodeAlive for codebases that exceed the model’s context limit — semantic search retrieves only the relevant slice.
Scoped Rules
Use
globs in .cursor/rules/*.mdc to apply CodeAlive guidance only where it matters.Team Standards
Share
.cursor/rules/codealive.mdc via git to keep the whole team on the same workflow.Troubleshooting
CodeAlive not responding
CodeAlive not responding
Solutions:
- Check the server status indicator in Settings → Tools & MCP (green = healthy, red = failed)
- Verify your API key is correct and active
- Reload Cursor:
Cmd/Ctrl+Shift+P → "Developer: Reload Window" - Check network connectivity to
https://mcp.codealive.ai/api
Incomplete code context
Incomplete code context
Solutions:
- Ensure your repositories are fully indexed in the CodeAlive dashboard
- Wait for indexing to complete
- Verify the API key has access to the relevant repositories
- Check repository filters
Slow responses
Slow responses
Solutions:
- Use more specific queries
- Limit search to specific repositories
- Check indexing status in dashboard
- Consider the Docker option for lower-latency local-network deployments
Related Resources
- Instructing Coding Agents
- CodeAlive & 1С (1C:Enterprise specifics)
- MCP Overview
- Self-Hosting Guide
- API Reference
- Cursor MCP Documentation
- Cursor Rules Documentation
Instruct Your Agent
Connecting CodeAlive makes its tools available, but the agent may still default to its built-in search. For reliable results, add a short instruction in the agent’s native format telling it to prefersemantic_search and grep_search when exploring indexed code. See Instructing Coding Agents.