Grok Code
Grok coding assistant for VS Code — agentic chat with workspace tools, plan mode, subagents, skills, and MCP. Built for xAI Grok (not a CLI wrapper).

Features
- Chat — streaming replies, reasoning / thinking blocks, image attachments
- Agent tools — read / write / search files, terminal, git, web search & fetch
- Plan mode — explore & design first, then approve and build
- Permissions — Manual · Plan · Accept edits · Bypass; allowlists for tools, shell, MCP
- Checkpoints — fork conversation, rewind agent file edits, or both
- Subagents — parallel workers (explore / plan / review / general), cancel, shared scratchpad, status dock
- Skills & plugins — Grok Build–compatible skills and plugin marketplace
- MCP — tools from
~/.grok/grokcode/mcp.json
- Sessions — history, compact, resume after window reload (with file undo checkpoints)
- Auth — browser OAuth, device code, or paste API token (Secret Storage)
Requirements
- VS Code 1.98 or later
- xAI access — console.x.ai API key and/or Grok subscription for OAuth
Quick start
- Install Grok Code from the Marketplace (or load the
.vsix)
- Open the Grok Code activity bar icon (or command Grok Code: Open)
- Sign in (browser / device) or paste a token
- Open a workspace folder and ask Grok to work on your project
Tips
@file / @folder mentions and + File add context chips
/plan, /compact, /agents, /permissions, /help — slash commands
- Permission mode chip in the composer: Manual / Plan / Auto-edit / Bypass
- Hover a message for Fork / Rewind code / Fork + rewind
Settings (highlights)
| Setting |
Default |
Description |
grokcode.model |
grok-4.5 |
Chat model |
grokcode.baseUrl |
https://api.x.ai/v1 |
API base URL |
grokcode.reasoningEffort |
medium |
Reasoning effort when supported |
grokcode.subagents.enabled |
true |
Allow spawn_subagent |
grokcode.subagents.maxConcurrent |
4 |
Max concurrent subagents |
grokcode.mcp.enabled |
true |
Load MCP tools |
grokcode.webSearch.enabled |
true |
web_search / web_fetch |
grokcode.autoCompact |
true |
Auto-compact long history |
Global agent permissions live in ~/.grok/grokcode/permissions.json (also editable in the extension UI).
Commands
- Grok Code: Open — editor tab (movable)
- Grok Code: Focus Sidebar
- Grok Code: New Chat
- Grok Code: Sign In with Grok / Device Code / Paste Token
- Grok Code: Undo Last Agent Edits
- Grok Code: Compact Chat History
Privacy & data
- Chat content and workspace paths are sent to the configured xAI API endpoint to generate replies and tool plans.
- Tokens are stored in VS Code Secret Storage (not in plain settings).
- Sessions and checkpoints are stored locally under VS Code workspace state and
~/.grok/grokcode/.
- No separate GrokCode analytics server is bundled in this extension.
Develop
npm install
npm run compile
npm test
Press F5 (Run Extension) in this folder.
npm run package # → grokcode-0.1.0.vsix
License
MIT © xrquic
| |