Google's Gemini CLI Brings AI Coding to the Command Line,For Free
Google's new Gemini CLI is an open-source AI agent that works directly in your terminal, reading and writing files, running shell commands, and handling multi-step coding tasks without leaving the command line. Released under the Apache 2.0 license, the tool gives developers access to Google's Gemini 3 models with a free tier offering 1,000 requests per day and up to 60 requests per minute, plus a context window of 1 million tokens.
What Makes Gemini CLI Different From a Coding Chatbot?
The distinction between a chatbot and a coding agent matters. A chatbot answers questions; Gemini CLI is built to take action. Instead of returning a code snippet for you to copy and paste, the agent reads your actual codebase, proposes changes, runs your test suite, and reports back. If you ask it to "find every place we call the old billing endpoint, update them to the new one, and run the tests," the agent locates the relevant files, makes the edits, executes your tests, and shows you the results, all without you leaving the shell.
The engine behind this capability is called a ReAct loop, short for "reason and act." Instead of producing one big answer in a single shot, the agent works in a cycle: it reasons about the next step, takes an action by calling a tool, observes what the tool returns, then reasons again with that new information. This loop allows the agent to recover from its own mistakes rather than stopping at the first error. You stay in control, approving file writes and commands as they happen.
How to Get Started With Gemini CLI
- Installation Options: You can run it on demand with npx without installing anything, install it globally through npm, Homebrew, MacPorts, or Anaconda, or use it with no setup inside Google Cloud Shell. The tool runs on macOS, Linux, and Windows and requires Node.js 20 or newer.
- Authentication: Sign in with a personal Google account to access the free tier, which includes 1,000 daily requests and 60 requests per minute, with access to Gemini 3 models and the full 1 million token context window. No API key is required for the free tier.
- Built-in Tools: The agent can perform file operations like reading and writing code, run shell commands to execute tests and install packages, fetch web pages to pull in external content, and use Google Search to ground its answers in current information rather than relying only on training data.
What Tools and Features Does Gemini CLI Include?
Beyond the core ReAct loop, Gemini CLI includes several connected pieces that make it practical for real work. The agent supports the Model Context Protocol (MCP), an open standard for connecting AI agents to external tools and data sources. You can configure MCP servers in a settings file to let the agent reach systems beyond the built-in toolset, such as a database, an issue tracker, or an internal API, through one shared interface.
The tool also supports a GEMINI.md file that you can place in a project to give the agent standing context, such as conventions, architecture notes, or commands to prefer, so it does not have to relearn your project every session. Conversation checkpointing lets you save and resume a working session, and token caching reduces repeated work on context the agent has already processed. Together these features keep long tasks coherent and cut the friction of starting over.
Beyond the interactive prompt, Gemini CLI runs non-interactively for scripting and automation, including structured output via JSON format, which makes it easy to wire into pipelines. There is also an official GitHub Action that brings the agent into your repository for tasks like pull-request review and issue triage, and you can mention @gemini-cli to invoke it on a thread.
What Are the Limits and Pricing?
The free tier is genuinely usable. Signing in with a personal Google account gives you 1,000 requests per day and 60 requests per minute, with access to the Gemini 3 models and the 1 million token context window. These numbers are vendor-reported and were verified on June 16, 2026; Google frames the allowance as generous but subject to change, so you should confirm the current figures before you rely on them for production work.
For developers who need higher limits, alternative authentication paths are available. A Gemini API key from Google AI Studio lets you stay on a free daily allowance and then move to paid tiers as your usage grows. The full source code is available on GitHub for anyone to inspect, fork, or extend, which is unusual for a flagship coding agent and matters if you care about auditability or self-hosting your tooling.
Why Open Source Matters for Coding Agents
The fact that Gemini CLI is fully open source under the Apache 2.0 license sets it apart in a landscape where most commercial coding agents keep their internals proprietary. The entire codebase is on GitHub for anyone to inspect, fork, or extend. This transparency is particularly important for teams that need to audit their AI tools, understand how they work, or run them on their own infrastructure without relying on cloud services.
The 1 million token context window available with the Gemini 3 model family is large enough to let the agent reason across a substantial codebase in one pass, holding many files, logs, or documentation in view rather than working one fragment at a time. This capability makes it practical for refactoring large projects or understanding complex systems without having to break the work into tiny pieces.