# Best Claude Code Alternatives

_Pick an alternative by the models you want and the plan you already pay for. Most of them can also run beside Claude Code instead of replacing it._

Claude Code is Anthropic's [coding agent](/learn/concepts/ai-engineering/coding-agents). It runs in the terminal, VS Code, JetBrains, a desktop app and the browser, and it runs Claude models only. People look for an alternative when they want other vendors' models, a free tier, open source code, or an agent bundled with a plan they already have. Every price and product fact below was checked on the vendor's own site as of December 4, 2026. Sources are listed at the end.

## Decision Table

| Tool | License | Entry price | Models | Pick it if |
| --- | --- | --- | --- | --- |
| Claude Code | Proprietary | Claude Pro, $20 per month billed monthly. Not in the free plan | Claude only, Opus 5.5 by default | You want Claude models from the vendor that trains them |
| Codex CLI | Apache 2.0 | Included in every ChatGPT plan, including Free | OpenAI models, GPT-6.2 Astra and Sol recommended | You already pay for ChatGPT or want sandboxing on by default |
| OpenCode | MIT | Free with your own provider. OpenCode Go from $10 per month | 200+ providers through models.dev, plus local models | You want to switch models or run them locally |
| Grok Build, formerly Cursor | Proprietary | Free tier. Plus at $8 per month | Grok and Composer models. Claude and Gemini from Premium up at API list price | You want an editor and an agent in one app |
| GitHub Copilot CLI | Proprietary | Included in Copilot Free. Pro is $10 per month | Claude, GPT, Gemini and other models, or your own provider | Your team already pays for Copilot |
| Antigravity CLI | No source published | Free for individuals with Gemini 4 Hydrogen | Gemini 4 models, plus Claude Sonnet 5.5 and Opus 5.5 on Google AI Pro and Ultra | You want Gemini in the terminal |
| Aider | Apache 2.0 | Free with your own provider | Almost any model, including local models | You want every edit committed to git |

## Treq Runs Claude Code Alongside the Others

[Treq](/) is not a Claude Code alternative. It is a free, open source desktop app that runs coding agents, Claude Code included, each in its own [workspace](/docs/concepts/workspaces). It can start Claude Code, Codex, Cursor Agent, GitHub Copilot CLI, Devin and Gemini CLI, as the [agent sessions](/docs/concepts/agent-sessions) page lists. If you are choosing between Claude Code and another agent, you can run both on the same repository and compare their diffs on the same task.

## 1. Codex CLI

Codex CLI is OpenAI's terminal agent, released under Apache 2.0. Every ChatGPT plan includes Codex: Free, Go at $8, Plus at $20, Pro from $100 per month, and Business at $25 per user billed monthly. You can also pay per token with an API key. OpenAI recommends GPT-6.2 Astra for demanding work and GPT-6.2 Sol for everyday coding.

The main difference from Claude Code is the safety default. Codex sandboxes commands by default, with Seatbelt on macOS, bubblewrap on Linux and WSL2, and a native Windows sandbox. Claude Code's sandbox is off until you turn it on, and it does not run on native Windows. See [Claude Code vs Codex CLI](./claude-code-vs-codex-cli.mdx).

## 2. OpenCode

OpenCode is an MIT-licensed agent with a terminal UI, a desktop app, a mobile app and an SDK. It connects to more than 200 providers through models.dev, including local models, and you can sign in with ChatGPT Plus or Pro or a GitHub Copilot account. OpenCode itself is free. OpenCode Go, an optional subscription for a curated set of models, starts at $10 per month.

OpenCode allows every action by default, except reads of `.env` files, which ask first. Its shell runs with your user's full access. Add deny rules or run it in a container before you leave it unattended. See [OpenCode vs Claude Code](./opencode-vs-claude-code.mdx).

## 3. Grok Build, Formerly Cursor

Cursor was renamed Grok Build on November 30, 2026. The desktop editor is now the Grok Build desktop app, and the announcement says the core app is unchanged. Scripts that call the old `agent` command keep working.

The free tier has limited agent requests. Plus costs $8 per month and runs only Grok 4.7, 4.6, 4.5 and Composer 2.5. Premium at $30, Super at $100 and Ultra at $200 add third-party models such as Claude and Gemini, billed separately at API list price. Pick it over Claude Code if you want to edit and delegate in one window. See [Cursor vs Claude Code](./cursor-vs-claude-code.mdx).

## 4. GitHub Copilot CLI

Copilot CLI runs in the terminal on macOS, Linux and Windows. GitHub's plans page lists it in Free, Pro at $10, Pro+ at $39 and Max at $100 per user per month. Usage draws on GitHub AI Credits, and the rate depends on the model. The model list includes Claude Opus 5.5 and Sonnet 5.5, GPT-6.2 Sol and Gemini 4 Neon.

You can also point Copilot CLI at your own provider. It accepts OpenAI-compatible, Azure and Anthropic endpoints, which covers local models through Ollama or vLLM. `copilot -p` runs a prompt headless and exits.

## 5. Antigravity CLI

Antigravity CLI is Google's terminal agent for individuals. The free plan uses Gemini 4 Hydrogen. Google AI Pro and Ultra add Gemini 4 Neon and Carbon, plus Claude Sonnet 5.5 and Opus 5.5. That makes it one way to reach Claude models outside a Claude plan. See [Claude Code vs Gemini CLI and Antigravity CLI](./claude-code-vs-gemini-cli.mdx).

## 6. Aider

Aider is an Apache 2.0 terminal agent that connects to almost any model, including local ones. It commits each change to git with a generated message, so you can undo any edit with ordinary git commands. It suits developers who want a small tool with a git history they can audit.

## How to Choose

- **You want models from more than one vendor.** OpenCode, Copilot CLI or Aider. Copilot CLI is the simplest if your company already buys Copilot.
- **You already pay for ChatGPT.** Codex CLI costs nothing extra.
- **You want an editor, not a terminal.** Grok Build, the former Cursor.
- **You want Claude models without a Claude plan.** Copilot CLI, Antigravity on Google AI Pro or Ultra, or Grok Build Premium.
- **You want safe defaults for unattended runs.** Codex CLI, which sandboxes commands by default.

[Best Coding Agent CLIs](./best-coding-agent-clis.mdx) compares every current terminal agent on permissions, sandboxing and headless use.

## Running Several Agents at Once

Two agents that edit one checkout overwrite each other's uncommitted changes. Give each agent its own git worktree, by hand or with a tool. [How to Run Multiple Claude Code Sessions](/learn/how-to/how-to-run-multiple-claude-code-sessions) covers the manual setup. [Best Tools for Running AI Coding Agents in Parallel](./best-parallel-agent-tools.mdx) compares the apps that do it for you.

## Sources

Checked December 4, 2026:

- Claude Code: [pricing](https://claude.com/pricing), [overview](https://code.claude.com/docs/en/overview), [model configuration](https://code.claude.com/docs/en/model-config), [sandboxing](https://code.claude.com/docs/en/sandboxing)
- Codex: [pricing](https://learn.chatgpt.com/docs/pricing), [models](https://learn.chatgpt.com/docs/models), [sandboxing](https://learn.chatgpt.com/docs/sandboxing), [repository](https://github.com/openai/codex)
- OpenCode: [home page](https://opencode.ai), [permissions](https://opencode.ai/docs/permissions/)
- Grok Build: [pricing](https://grok.com/pricing), [models and pricing](https://docs.grok.com/build/agents-window/models-and-pricing), [rename announcement](https://forum.cursor.com/t/cursor-is-now-grok-build/179623)
- GitHub Copilot: [plans](https://github.com/features/copilot/plans), [about Copilot CLI](https://docs.github.com/en/copilot/concepts/agents/about-copilot-cli)
- Antigravity: [pricing](https://antigravity.google/pricing)
- Aider: [repository](https://github.com/Aider-AI/aider)

## Next Steps

- [Codex Alternatives](./codex-alternatives.mdx): the same choice, starting from OpenAI's agent
- [Claude vs GPT for Coding](./claude-vs-gpt-for-coding.mdx): the models behind Claude Code and Codex
- [Review AI-Generated PRs](/learn/how-to/review-ai-generated-prs): check agent output before it merges
