Beta — Now available

Bring Grok into
your terminal

A powerful new coding agent and CLI for complex coding work. Plan, build, test, and deploy — all from the command line.

Get started Learn more
$ curl -fsSL https://x.ai/cli/install.sh | bash
✓ Installing Grok CLI...
✓ Ready.
$ grok build --help
A powerful coding agent for your terminal.

Adapt to your workflows

Grok CLI adapts to your workflows and preferences with skills that work out of the box.

01

Plug-and-play compatibility

AGENTS.md, plugins, hooks, and MCP servers all work out of the box. No configuration needed.

02

Auto-invoked by context

Skills fire automatically when a task matches, or call them by name. Capture any session with /skillify.

03

Plan mode for architecture

The plan viewer makes it easy to architect complex projects. Start in plan mode — every edit is blocked until you approve.

04

Approve, comment, or rewrite

Approve the plan, comment on individual steps, or rewrite it entirely. Every change shows up as a clean diff.

05

Marketplace plugins

Bundle skills, agents, hooks, and MCP servers behind one install. Marketplace install or self-host from any git repo.

06

Subagent parallelism

Grok CLI delegates larger tasks to specialized subagents. Each child runs in parallel with its own context window.

One tool for the entire workflow

Plan, build, test, and deploy — everything lives in one terminal interface.

01

Inspect the task

The agent reads the context, understands the target, and decides what to change. Ambiguous tasks get a quick multiple-choice to nail the details.

02

Edit and build

Architecture, logic, tests, and configuration all live in the same workspace. Multi-file edits with search-and-replace.

03

Run and verify

Terminal execution streams builds and tests live. Background tasks monitor long-running processes.

04

Review and ship

Line-by-line code review before opening a PR. Git integration for stage, commit, push, and branch management.

One tool, every capability

From planning to deployment, Grok CLI covers the full development workflow.

Plan mode

Propose a structured approach before writing code.

Subagents

Spawn parallel agents for testing and research.

Skills

Turn workflows into reusable slash commands.

Hooks

Run scripts on file edits and tool calls.

MCP servers

Connect to Linear, Sentry, Grafana, and more.

AGENTS.md

Set conventions and rules per directory.

Memory

Persist decisions and context across sessions.

Code search

Grep and navigate large codebases fast.

Multi-file edits

Refactor across files with search-and-replace.

Git integration

Stage, commit, push, and manage branches.

Deep reasoning

Step-by-step thinking for hard problems.

Web search

Look up docs and packages from the terminal.

Terminal execution

Run builds and tests with live streaming.

Headless mode

Script Grok CLI in CI/CD pipelines.

Code review

Line-by-line feedback before opening a PR.

Sandboxed execution

Run untrusted code in isolated environments.

Background tasks

Monitor long-running builds and processes.

Theming

Customize colors, fonts, and appearance.

Grok CLI asks the right questions

Ambiguous tasks get a quick multiple-choice. Pick a direction, a framework, or a schema — answers flow straight into the plan.

Waiting on answers for 3 questions · turn: 7.1s
1 / 3
Design direction
2 / 3
Framework preference
3 / 3
Schema decisions
Type your answer here...

Common questions

Start here if you want to know what Grok CLI is, how it works, and how to get started.

What is Grok CLI?
Grok CLI is a powerful coding agent and command-line interface for complex coding work. It brings Grok's capabilities into your terminal, letting you plan, build, test, and deploy code through natural language commands and an intelligent agent system.
How do I install Grok CLI?
One command to install: curl -fsSL https://x.ai/cli/install.sh | bash. Works with any codebase, any language, right now. Grok CLI is available to SuperGrok and X Premium+ subscribers.
What can Grok CLI do?
Grok CLI covers the entire development workflow: plan mode for architecture, subagents for parallel work, skills for reusable commands, hooks for automation, MCP server integration, code search, multi-file edits, git integration, deep reasoning, web search, terminal execution, code review, and more. One tool for everything.
Does Grok CLI support MCP servers?
Yes. Connect to Linear, Sentry, Postgres, Grafana, browsers — anything with MCP works out of the box. Bundle skills, agents, hooks, and MCP servers behind one install through the marketplace or self-host from any git repo.
What is plan mode?
Plan mode lets you start with a structured approach for complex tasks. Every edit is blocked until you approve the plan. You can approve individual steps, comment on them, or rewrite the plan entirely. Every approved change shows up as a clean diff.
How do subagents work?
Grok CLI delegates larger tasks to specialized subagents. Each child runs in parallel with its own context window, enabling deep worktree support. Launch subagents for research, testing, building, and reviewing — all at once.

Bring Grok into your terminal

Install now and start building with the early beta of Grok CLI.

Get started