Grok Build and Cursor announced an integration at launch using the Agent Client Protocol (ACP). This means you can use Grok Buildās multi-agent architecture as a backend for Cursorās IDE experience. You get Cursorās UI and inline editing with Grokās reasoning and tool use under the hood.
Hereās how to set it up, what it enables, and when it makes sense over using either tool alone. For Grok Build basics, see the complete guide. For a broader comparison of IDE-based tools, check Claude Code vs Cursor in 2026.
What Is ACP?
The Agent Client Protocol is a standard for connecting AI agent backends to frontend clients. Think of it like LSP (Language Server Protocol) but for AI agents instead of language features.
ACP defines how:
- A client (Cursor) sends tasks to an agent (Grok Build)
- The agent reports progress, requests input, and returns results
- Tool calls are routed and permissions are managed
- Multiple agents coordinate on complex tasks
Grok Build implements ACP as both a server (other tools can connect to it) and a client (it can connect to other ACP-compatible agents).
Prerequisites
Before starting:
- Grok Build installed and authenticated:
curl -fsSL https://x.ai/cli/install.sh | bash
grok auth
-
Cursor installed (version 0.45+ required for ACP support)
-
Active subscription: Either SuperGrok ($99/mo) or a valid xAI API key
Setup Steps
Step 1: Enable ACP Server in Grok Build
Start Grok Build in ACP server mode:
grok serve --protocol acp --port 9120
This starts a local ACP server that Cursor can connect to. The server runs in the background and handles requests from Cursor.
To start it automatically when you open a project:
// .grok/config.json
{
"serve": {
"autoStart": true,
"protocol": "acp",
"port": 9120
}
}
Step 2: Configure Cursor
Open Cursor settings and add Grok Build as an agent backend:
- Open Settings (
Cmd+,on macOS,Ctrl+,on Linux) - Navigate to AI > Agent Backends
- Click Add Backend
- Enter the connection details:
{
"name": "Grok Build",
"protocol": "acp",
"url": "http://localhost:9120",
"capabilities": ["code", "plan", "ask", "tools"]
}
Step 3: Verify the Connection
In Cursorās command palette (Cmd+Shift+P):
> Agent: Check Backend Status
You should see āGrok Build: Connectedā with the available capabilities listed.
Step 4: Select Grok Build as Your Agent
In Cursorās AI panel, switch the backend from the default to Grok Build:
- Click the model selector dropdown
- Under āAgent Backends,ā select Grok Build
- Choose the mode: Code, Plan, or Ask
How It Works in Practice
Once connected, Cursor routes your AI requests through Grok Build instead of its built-in models. Hereās what changes:
Inline Edits
When you select code and press Cmd+K, the edit request goes to Grok Build. You get Grokās 256K context window and reasoning capabilities applied to Cursorās inline edit UI.
Chat Panel
The chat panel becomes a Grok Build session. It has access to your full project context, can spawn subagents for complex tasks, and uses Grokās native tool calling.
Composer (Multi-file Edits)
This is where the integration shines. Cursorās Composer mode + Grok Buildās multi-agent architecture means:
- Grok Build spawns parallel subagents for different files
- Each subagent handles its portion of the task
- Results are coordinated and presented in Cursorās diff view
- You review and accept/reject changes per file
Terminal Commands
Grok Build can execute terminal commands through Cursorās integrated terminal. Permission prompts appear in Cursorās UI rather than a separate terminal window.
Use Cases
When to use Grok Build via Cursor
- You prefer a visual IDE over terminal-only interaction
- You want inline code suggestions powered by Grokās reasoning
- Multi-file refactoring with visual diffs
- Youāre already a Cursor user and want to try Grokās models
When to use Grok Build standalone
- CI/CD automation (headless mode)
- You prefer terminal workflows
- You need full control over subagent configuration
- Youāre using hooks and skills that need direct CLI access
When to use Cursorās built-in models
- Quick inline completions (lower latency)
- You donāt need multi-agent orchestration
- Cost sensitivity (Cursor Pro includes model access)
Advanced Configuration
Custom Model Routing Through Cursor
You can configure which Grok model handles which type of request:
// .grok/config.json
{
"routing": {
"inline_edit": "grok-3-fast",
"chat": "grok-3",
"composer": "grok-3",
"ask": "grok-3-mini"
}
}
This routes quick inline edits to the faster model while using the full model for complex multi-file operations.
Sharing Context Between Cursor and Grok Build
Grok Build reads CLAUDE.md natively (yes, the same file Claude Code uses). If you already have a CLAUDE.md in your project root, Grok Build picks it up automatically and uses it as project context, even when accessed through Cursor.
<!-- CLAUDE.md (also read by Grok Build) -->
# Project Context
- This is a Next.js 15 app with App Router
- We use Drizzle ORM with PostgreSQL
- Tests are in Vitest, not Jest
- All API routes return typed responses using Zod schemas
Permission Handling
When Grok Build needs to perform an action that requires permission (file writes, shell commands), the permission prompt appears in Cursorās UI as a notification. You can pre-approve actions in your Grok config:
{
"permissions": {
"autoApprove": ["read_file", "write_file", "list_directory"],
"requireConfirmation": ["shell_command", "delete_file"]
}
}
Troubleshooting
āBackend not respondingā
Check that the Grok Build ACP server is running:
# Check if the process is alive
ps aux | grep "grok serve"
# Restart it
grok serve --protocol acp --port 9120
āCapabilities mismatchā
Update both Grok Build and Cursor to their latest versions. ACP capability negotiation requires compatible versions.
grok update
High latency on inline edits
Switch inline edits to grok-3-fast in your routing config. The full grok-3 model is overkill for single-line completions.
FAQ
Does this cost extra beyond my Grok Build subscription?
No. The ACP integration uses your existing Grok Build authentication. Token usage counts against your normal limits (SuperGrok plan or API key billing).
Can I use both Cursorās built-in AI and Grok Build simultaneously?
Yes. You can switch between backends per-request. Use Cursorās built-in for quick completions and Grok Build for complex multi-file tasks.
Does Grok Buildās ACP server work with other editors?
ACP is an open protocol. Any editor that implements an ACP client can connect to Grok Buildās server. As of May 2026, Cursor is the only editor with official support, but the protocol spec is public.
Is my code sent to xAIās servers?
Yes. Grok Build processes code on xAIās infrastructure. The same privacy policy applies whether you use Grok Build via CLI or through Cursor. Code is not used for training by default.
Can I run multiple ACP backends in Cursor?
Yes. You can configure multiple backends and switch between them. For example, use Grok Build for planning and Claude Codeās ACP server for implementation.
Does the Cursor integration support Grok Buildās Plan Mode?
Yes. When you select āPlanā mode in the Cursor AI panel, it maps to Grok Buildās plan mode. You get a structured plan in the chat panel that you can approve before execution begins.