Grok CLI embeds conversational AI directly into your terminal environment. Powered by Grok-3, the tool interprets natural language instructions and translates them into system actions. Whether you need to inspect a file, generate new code, or run shell commands, you can simply describe the task in plain English. Grok identifies the necessary utility and executes the work on your behalf. The entire experience is housed in an interactive terminal UI that supports project-specific custom instructions to refine the AI's behavior.
Natural Language Interface
Interact with your machine through a conversational interface driven by Grok-3. Communicate with your system as easily as you would with a colleague.
Intelligent File Management
Grok automatically determines the best approach to view, create, or modify files. You focus on the content while the AI handles the specific file operations.
Bash Integration
Execute shell commands via conversation. Instead of struggling with obscure flags and syntax, describe the desired outcome and let Grok construct the command for you.
Contextual Tool Selection
The assistant analyzes your request and selects the appropriate tool from its internal suite. This allows you to stay focused on the high-level task rather than the underlying mechanics.
Interactive Terminal UI
Built on the Ink framework, the interface is clean, responsive, and highly readable, transforming the terminal into a more intuitive workspace.
Global Installation
A simple npm i -g @vibe-kit/grok-cli makes the tool available system-wide. Once installed, you can launch the assistant from any directory by typing grok.
Requirements:
npm install -g @vibe-kit/grok-cli
git clone <repository>cd grok-clinpm installnpm run buildnpm linkAfter acquiring your API key from X.AI, you can authenticate using one of the following methods:
Environment Variableexport GROK_API_KEY=your_api_key_here
.env File
Rename .env.example to .env and insert your key into the designated field.
Command Line Flag
Pass the key directly when starting the tool:grok --api-key your_api_key_here
grokgrok -d /path/to/projectYou can tailor Grok’s behavior by placing a .grok/GROK.md file in your project’s root directory. The assistant reads this file upon startup and adjusts its responses to match your project requirements.
mkdir .groktouch .grok/GROK.md# Grok CLI Custom Instructions
- Write all new code in TypeScript.
- Use React functional components with hooks.
- Prefer explicit typing and const assertions over inferred types for better clarity.
- Include JSDoc comments for all public functions and interfaces.
- Maintain consistency with the existing code style and architectural patterns in this project.
Grok loads these rules automatically when operating within that directory. These instructions are appended to the system prompt, ensuring the AI prioritizes your project's standards over its default settings.
Instead of memorizing commands, simply tell Grok what you need to achieve:
💬 "Show me what's inside package.json"
💬 "Create a file called hello.js that contains a simple console.log"
💬 "Find all TypeScript files located in the src directory"
💬 "Replace oldFunction with newFunction in all JavaScript files"
💬 "Execute the test suite and display the output"
💬 "Show me the current directory structure"
Tencent HunyuanVideo-1.5: 8.3B Video Model Runs on 14GB GPUs
GRAG: Continuous Image Editing Control for DiT Models
AI Presentation Generator: An Open-Source Gamma Alternative for Slide Decks
Common Ground: Multi-Agent Collaboration That Actually Works
MindForger Review: A Private Markdown IDE for Personal Knowledge Management
TensorZero: Optimize LLM Applications with Production Feedback
Mevzuat MCP: Search Turkish Legislation Directly in Claude
Dots.LLM1: 142B MoE Model Trained on 11.2T Real-World Tokens
BAGEL 7B MoT: The Open Multimodal Model Outperforming Qwen2.5-VL
Jitsi Meet Review: Open-Source Video Conferencing That Just Works
Nping: A High-Performance Concurrent Ping Tool in Rust with Live Charts
Add Area Fill to Line Charts in Excel: Step-by-Step