Ninja Builder Sign in Get started

Gemini CLI vs Claude Code in December 2026: which terminal agent should you use?

Gemini CLI now serves Code Assist and API key users, while Claude Code comes with Claude plans. Here's how they compare on access, cost, setup, features and MCP.

By Ninja Builder team7 min read
Title card reading Gemini CLI vs Claude Code, with a terminal window for each agent

Key takeaways

  • Since 18 June 2026 Gemini CLI no longer serves free users or Google AI Pro and Ultra; they moved to Antigravity CLI.
  • Gemini CLI still works for Gemini Code Assist business licences, paid Gemini API keys and Vertex AI.
  • Claude Code comes with Claude plans from $20 a month (checked 6 December 2026) or a Console API account.
  • Claude Code runs in more places (IDEs, desktop app, web); Gemini CLI is open source and terminal-first.
  • Both read a project rules file (CLAUDE.md or GEMINI.md) and support MCP with nearly the same commands.

Gemini CLI vs Claude Code is a different question in December 2026 than it was a year ago. Claude Code is Anthropic's coding agent, included in Claude's paid plans. Gemini CLI is Google's open-source terminal agent, but since 18 June 2026 it no longer serves free users or Google AI Pro and Ultra subscribers: those people moved to Antigravity CLI. Gemini CLI now serves companies on Gemini Code Assist and developers with a paid Gemini API key or Vertex AI.

So the real choice is usually: Claude Code on a Claude plan, or Gemini CLI on a Google API key or business licence. This article compares the two on access and cost, setup, everyday features, project rules and MCP, and ends with who should pick which. Facts come from Anthropic's Claude Code docs and pricing page, and from Google's Gemini CLI repository and docs, all checked on 6 December 2026.

Gemini CLI vs Claude Code: the short answer

  • Pick Claude Code if you want a flat monthly price, you already pay for Claude, or you want the agent that most guides, skills and tools are written for today.
  • Pick Gemini CLI if your company has a Gemini Code Assist Standard or Enterprise licence, you already pay for Gemini API or Vertex AI usage, or you need an open-source agent you can read and change.
  • Pick neither, pick Antigravity CLI, if you wanted Gemini CLI because it was free or because you pay for Google AI Pro or Ultra. That's where those plans went. We cover the move in Gemini CLI is gone: how to move to Antigravity CLI.

Gemini CLI vs Claude Code side by side

Claude CodeGemini CLI
Made byAnthropicGoogle
Source codeAnthropic's productOpen source, Apache 2.0 licence
Who can use it todayAnyone on Claude Pro, Max, Ultra, Team or Enterprise, or a Console API accountGemini Code Assist business users, paid Gemini API keys and Vertex AI; not free or Google One plans since 18 June 2026
How you payFlat monthly plan from $20 (Pro), or per token with an API keyYour Code Assist licence, or per use on your API key or Google Cloud bill
Where it runsTerminal, VS Code, JetBrains, Claude desktop app, webTerminal, with a VS Code companion for IDE integration
InstallNative installer, Homebrew, WinGet, Linux packages; no Node.js needednpm, Homebrew or MacPorts; needs Node.js for npm
ModelsAnthropic's Claude modelsGemini models; Google says it is not optimised for Gemini 4 models
Project rules fileCLAUDE.md, or an existing AGENTS.mdGEMINI.md
MCP serversclaude mcp add; scopes local, project, usergemini mcp add; scopes project, user
Scriptingclaude -p "…"gemini -p "…", with JSON output options

Access and cost: the biggest difference

Claude Code

Claude Code comes with Claude's paid plans. On 6 December 2026 the pricing page lists Pro at $20 a month ($17 billed yearly), Max at $100 and Ultra at $200, with Team seats from $20 billed yearly. Usage refills every five hours and every week, so you know your monthly bill in advance, and you wait (or buy extra usage) when you reach a limit. You can also sign in with a Console account and pay per token. The full breakdown is in our Claude Code pricing guide.

Gemini CLI

Gemini CLI was famous for a generous free tier when you signed in with a personal Google account. That's over. The repository now says free individual access and Google AI Pro and Ultra moved to Antigravity CLI on 18 June 2026. What still works:

  • Sign in with Google for a paid Gemini Code Assist licence, with your Google Cloud project set.
  • A Gemini API key from Google AI Studio, set as GEMINI_API_KEY. You pay by usage and can choose the model.
  • Vertex AI on Google Cloud, billed to your cloud account.

Google's docs point out that the sign-in method you pick changes your quotas, pricing and terms, and the Gemini CLI pages don't list prices. Check Google's own Gemini API pricing before you rely on it. In short: Claude Code is a subscription with limits, Gemini CLI is now mostly pay as you go.

Setup compared

Claude Code installs with one command and updates itself: curl -fsSL https://claude.ai/install.sh | bash on Mac, Linux or WSL, or irm https://claude.ai/install.ps1 | iex in PowerShell. Then run claude in your project and sign in in the browser. Step-by-step help is in how to install Claude Code.

Gemini CLI installs with npm install -g @google/gemini-cli, brew install gemini-cli, or runs once without installing through npx @google/gemini-cli. Then run gemini and pick a sign-in method, or set your API key first. It has preview, stable and nightly release channels if you want new features early.

Both take a few minutes. Claude Code's native installer has the edge for beginners because it needs no Node.js, and it works without a terminal through the Claude desktop app. Gemini CLI is terminal-first.

Day-to-day features

In everyday use the two feel similar: you open a terminal in your project, describe a task, and the agent reads files, edits them and runs commands, asking first. Both can run once from a script with -p. The differences are in the extras.

Where Claude Code goes further

  • More places to work. Official VS Code and JetBrains extensions, a desktop app with visual diffs, a web version for long cloud tasks and the Claude phone app to check in on them.
  • A bigger toolbox. Skills, plugins, hooks, sub-agents that split a big task, scheduled tasks, and permission modes you switch with Shift+Tab.
  • Automation. The same agent runs in GitHub Actions and GitLab CI for code review and issue triage.

Where Gemini CLI stands out

  • Open source. You can read the code, report issues and build your own version, under the Apache 2.0 licence.
  • Built-in web search and fetch, alongside file and shell tools.
  • Checkpointing, sandboxing and trusted folders to limit what the agent can touch and roll back its changes.
  • Google Cloud fit. Vertex AI sign-in and Code Assist licences slot into a company's existing Google Cloud setup.

One caution from Google itself: Gemini CLI is "not optimized for Gemini 4+" models, and Google asks people not to use it for model benchmarks. If you want Google's newest models in a terminal, Antigravity CLI is where Google is putting that work.

Project rules and MCP servers

Both agents read a rules file from your project at the start of every session: CLAUDE.md for Claude Code and GEMINI.md for Gemini CLI. Claude Code can also read an existing AGENTS.md. If you use both, keep one shared file and point the other at it; our guide to CLAUDE.md and AGENTS.md shows how.

Both support MCP servers, with nearly the same commands:

# Claude Code (default scope: local, just you in this project)
claude mcp add --transport http notion https://mcp.notion.com/mcp
claude mcp list

# Gemini CLI (default scope: project, default transport: stdio)
gemini mcp add [options] <name> <commandOrUrl> [args...]
gemini mcp list

Watch the defaults: Claude Code saves a new server for just you unless you pass --scope project, while Gemini CLI saves to the project's settings unless you pass --scope user. Gemini CLI keeps servers in the mcpServers section of its settings.json; Claude Code shares project servers in .mcp.json. Both have an /mcp command for status. Our Claude Code MCP guide has every command and fix, and what is MCP explains the idea.

Who should pick which

  • You're a solo developer or beginner: Claude Code. A flat plan is easier to budget than per-use billing, and you can use it without a terminal.
  • Your company standardised on Google Cloud with Code Assist: Gemini CLI. It's included in your licence and Google says it keeps updating it for business users.
  • You pay for Google AI Pro or Ultra: Antigravity CLI, not Gemini CLI. Or Claude Code if you'd rather switch providers.
  • You need open source or want to customise the agent itself: Gemini CLI.
  • You want the widest choice of editors and ways to work: Claude Code.

The fairest test is to give both the same real task from a clean Git state and compare the diffs, not the summaries. Our Claude Code vs Codex vs Copilot CLI comparison describes a test you can reuse, and if you're also weighing an editor, see Claude Code vs Cursor.

Claude and Gemini in one desktop app

You don't have to choose one for good. Ninja Builder is a desktop app for Mac, Windows and Linux where you add your AI accounts once and pick one per chat. A Claude account runs Claude Code with your own Claude plan. A Gemini account uses an API key from Google AI Studio: paste it in Settings › Accounts › Add account and click Test; Google bills the key to your AI Studio account.

A chat can even move between Claude and Gemini and keep going: the new AI gets the conversation so far, including which files were read or changed. Ninja Builder also follows your GEMINI.md and AGENTS.md files alongside CLAUDE.md. Download Ninja Builder to try both with the accounts you already have.

Frequently asked questions

Is Gemini CLI better than Claude Code?

It depends on how you pay. Claude Code suits people who want a flat Claude plan and the most ways to work. Gemini CLI suits companies on Gemini Code Assist or developers paying per use with a Gemini API key, and anyone who needs open source.

Is Gemini CLI still free?

No. Google moved free individual access and Google AI Pro and Ultra subscribers to Antigravity CLI on 18 June 2026. Gemini CLI now works with Code Assist business licences, paid Gemini API keys and Vertex AI.

Can I use Gemini CLI and Claude Code together?

Yes. Use one shared rules file such as AGENTS.md, give each agent its own branch or take turns, and use one to review the other's work.

Does Gemini CLI support MCP like Claude Code?

Yes. Gemini CLI uses gemini mcp add, list and remove, and stores servers in settings.json. Claude Code uses claude mcp add, list and remove, and shares project servers in .mcp.json.

What replaced Gemini CLI?

For free users and Google AI Pro and Ultra subscribers, Antigravity CLI (the agy command) replaced Gemini CLI on 18 June 2026. Gemini CLI itself continues for business and paid API users.

Keep reading