Coding assistants and agents9 projects, checked September 17, 2026

Open-source alternatives to Claude Code

The open-source alternatives to Claude Code are OpenCode, Qwen Code, Crush, goose, gptme, Cline, OpenHands, Codex CLI and Gemini CLI. The first seven work with any model, and Qwen Code, Crush, goose, gptme and Cline document local models through Ollama or llama.cpp, so the whole loop can run on your own machine. Codex CLI and Gemini CLI are open-source agents tied to OpenAI's and Google's hosted models. Qwen Code's own README says that if you know Claude Code, you already know Qwen Code. A developer switches to choose the model, or to keep code local.

A terminal agent with a planning mode
OpenCode
Switching between hosted and local models at runtime
Qwen Code
The widest provider list with local models
Crush

8 of 9 carry an OSI licence. 7 of 9 run on your own machines. Figures read from GitHub on September 17, 2026.

Pick by need

One project per need, with the reason from its own README and the one thing to know before you choose it.

A terminal agent with a planning mode

OpenCode

MIT, a full-access build agent and a read-only plan agent switched with Tab, installers for every platform, a beta desktop app, and the largest community in this directory by stars.

Know firstThe README states no providers, MCP or local-model details; the docs site does.

OSI208,214 stars

Switching between hosted and local models at runtime

Qwen Code

Apache-2.0, with OpenAI, Anthropic, Gemini and Qwen APIs or Ollama and vLLM, editor plugins, a desktop app, MCP, a sandbox and subagents. Its README says if you know Claude Code, you already know Qwen Code.

Know firstWeb UI and daemon mode are experimental; benchmark numbers are its own.

OSI27,935 stars

The widest provider list with local models

Crush

28 hosted providers plus llama.cpp, Ollama, LM Studio and LiteLLM, MCP over stdio, HTTP and SSE, language servers, and permission prompts on every tool call by default.

Know firstFunctional Source License: no competing commercial use until each version turns MIT two years after release; usage metrics on by default.

Source available28,153 stars

A desktop app and a CLI under foundation governance

goose

Apache-2.0, part of the Agentic AI Foundation at the Linux Foundation, 15+ providers including Ollama, existing Claude, ChatGPT and Gemini subscriptions, and 70+ MCP extensions.

Know firstThe README says little about file, command and web capabilities; the docs do.

OSI54,402 stars

A general-purpose local agent that also codes

gptme

MIT, shell and Python locally, file patching, a browser, screenshots, sandboxing in Docker or Wasmtime, llama.cpp for local models, and MCP as both client and server.

Know firstA single-maintainer project with several features its README lists as in progress.

OSI4,417 stars

The same agent in the IDE and headless in CI

Cline

Apache-2.0, a CLI with JSON output for scripting, VS Code and JetBrains extensions, a desktop app, any provider including Ollama, and approval on every action.

Know firstJetBrains plugin not open source.

OSI68,575 stars

Hosting Claude Code itself on your servers

OpenHands

MIT control centre that runs the OpenHands agent or Claude Code, Codex and any ACP agent in Docker and on your infrastructure, with automations from Slack, GitHub and Linear.

Know firstBeta, and its README warns two install routes give the agent full filesystem access.

OSI88,343 stars

OpenAI models with open agent code

Codex CLI

Apache-2.0 agent that runs locally, with a desktop app and IDE extensions, signed in with a ChatGPT plan or an API key.

Know firstOnly OpenAI's hosted models; no other provider and no local model.

OSI124,939 stars

A free tier on a Google account

Gemini CLI

Apache-2.0, with 1,000 requests a day on a personal Google account by its README, search grounding, shell and file tools, MCP and a GitHub Action.

Know firstOnly Google's hosted Gemini models; no other provider and no local model.

OSI107,045 stars

What to take away

  • Seven of the nine work with any model; Codex CLI and Gemini CLI are open agents tied to one vendor's hosted models.
  • Five document local models, so the entire loop can run on your own machine: Qwen Code, Crush, goose, gptme and Cline.
  • OpenCode, Cline and Qwen Code each ship a planning or approval mode, which is the safety question every terminal agent raises.
  • Crush is the one licence to read: source available under the Functional Source License, MIT two years after each release.
  • Claude Code still wins on being the agent Anthropic built around its own models, with Slack and web steering as a service.

The projects, side by side

The facts that decide most choices. Each project's page carries the full panel.

ProjectBest forOpennessLicenceRuns asOwn machinesStars
OpenCodeA terminal agent with a planning modeOSIMITCLI, Desktop app (beta)Yes208,214
Qwen CodeSwitching between hosted and local models at runtimeOSIApache-2.0CLI, VS Code, Zed and JetBrains plugins, Desktop app, Web UI (experimental), SDKs in TypeScript, Python and JavaYes27,935
CrushThe widest provider list with local modelsSource availableSee LICENSECLIYes28,153
gooseA desktop app and a CLI under foundation governanceOSIApache-2.0Desktop app, CLI, APIYes54,402
gptmeA general-purpose local agent that also codesOSIMITCLI (pipx, uv or pip), Web UI, Desktop app, MCP serverYes4,417
ClineThe same agent in the IDE and headless in CIOSIApache-2.0VS Code extension, JetBrains plugin, CLI, Desktop app, Node.js SDKYes68,575
OpenHandsHosting Claude Code itself on your serversOSIMITnpm package, Docker, From sourceYes88,343
Codex CLIOpenAI models with open agent codeOSIApache-2.0CLI, Desktop app, IDE extension for VS Code, Cursor and WindsurfNo124,939
Gemini CLIA free tier on a Google accountOSIApache-2.0CLI, VS Code companion, GitHub ActionNo107,045

Licence and star figures read from GitHub on September 17, 2026. Stars are shown as a dated fact and were not used to rank this page.

Each project, in turn

OpenCode

OSIA terminal agent with a planning mode

An MIT terminal coding agent with a full-access build agent and a read-only plan agent switched with the Tab key, installers for every platform, a beta desktop app, and the most-starred repository in this directory.

MIT, a full-access build agent and a read-only plan agent switched with Tab, installers for every platform, a beta desktop app, and the largest community in this directory by stars.

Know firstThe README states no providers, MCP or local-model details; the docs site does.

Licence
MIT
Runs as
CLI, Desktop app (beta)
Platforms
macOS (Apple Silicon and Intel), Linux, Windows
Hosted option
None from the maintainers
Last release
v1.18.31, Sep 14, 2026

Qwen Code

OSISwitching between hosted and local models at runtime

An Apache-2.0 coding agent from the Qwen team for the terminal, editor, desktop, browser and chat apps that works with OpenAI, Anthropic, Gemini and Qwen APIs or local models through Ollama and vLLM, switched at runtime, with MCP, a sandbox and subagents.

Apache-2.0, with OpenAI, Anthropic, Gemini and Qwen APIs or Ollama and vLLM, editor plugins, a desktop app, MCP, a sandbox and subagents. Its README says if you know Claude Code, you already know Qwen Code.

Know firstWeb UI and daemon mode are experimental; benchmark numbers are its own.

Licence
Apache-2.0
Runs as
CLI, VS Code, Zed and JetBrains plugins, Desktop app, Web UI (experimental), SDKs in TypeScript, Python and Java
Platforms
macOS, Linux, Windows
Hosted option
None from the maintainers
Last release
v0.24.0, Sep 16, 2026

Crush

Source availableThe widest provider list with local models

Charm's terminal coding agent with 28 provider integrations, local models through llama.cpp, Ollama and LM Studio, MCP over three transports and permission prompts by default, under the Functional Source License, which becomes MIT two years after each release.

28 hosted providers plus llama.cpp, Ollama, LM Studio and LiteLLM, MCP over stdio, HTTP and SSE, language servers, and permission prompts on every tool call by default.

Know firstFunctional Source License: no competing commercial use until each version turns MIT two years after release; usage metrics on by default.

Licence
See the LICENSE file
Runs as
CLI
Platforms
macOS, Linux, Windows (PowerShell and WSL), Android, FreeBSD, OpenBSD, NetBSD
Hosted option
Sold by the maintainers
Last release
v0.95.0, Sep 16, 2026

goose

OSIA desktop app and a CLI under foundation governance

An Apache-2.0 general-purpose AI agent from the Agentic AI Foundation at the Linux Foundation, written in Rust, with a desktop app, a CLI and an API, 15+ model providers including Ollama, and 70+ extensions over MCP.

Apache-2.0, part of the Agentic AI Foundation at the Linux Foundation, 15+ providers including Ollama, existing Claude, ChatGPT and Gemini subscriptions, and 70+ MCP extensions.

Know firstThe README says little about file, command and web capabilities; the docs do.

Licence
Apache-2.0
Runs as
Desktop app, CLI, API
Platforms
macOS, Linux, Windows
Hosted option
None from the maintainers
Last release
v1.51.0, Sep 17, 2026

gptme

OSIA general-purpose local agent that also codes

An MIT personal AI agent for the terminal that runs shell and Python locally, patches files, browses the web, works with Anthropic, OpenAI, Google, xAI, DeepSeek, OpenRouter or a local llama.cpp server, and is both an MCP client and an MCP server.

MIT, shell and Python locally, file patching, a browser, screenshots, sandboxing in Docker or Wasmtime, llama.cpp for local models, and MCP as both client and server.

Know firstA single-maintainer project with several features its README lists as in progress.

Licence
MIT
Runs as
CLI (pipx, uv or pip), Web UI, Desktop app, MCP server
Platforms
Anywhere a terminal runs with Python 3.10 or newer, Desktop app for Linux, macOS and Windows
Hosted option
Sold by the maintainers
Last release
v0.33.0, Aug 19, 2026

Cline

OSIThe same agent in the IDE and headless in CI

An Apache-2.0 coding agent for VS Code, JetBrains, the terminal and a desktop app that edits files as reviewable diffs, runs commands with your approval, works with any model provider including Ollama, and connects tools through MCP.

Apache-2.0, a CLI with JSON output for scripting, VS Code and JetBrains extensions, a desktop app, any provider including Ollama, and approval on every action.

Know firstJetBrains plugin not open source.

Licence
Apache-2.0
Runs as
VS Code extension, JetBrains plugin, CLI, Desktop app, Node.js SDK
Platforms
VS Code and JetBrains IDEs, Desktop app for macOS and Windows, CLI anywhere Node.js runs
Hosted option
None from the maintainers
Last release
desktop-v0.0.32, Sep 18, 2026

OpenHands

OSIHosting Claude Code itself on your servers

An MIT self-hosted control centre, called Agent Canvas, that runs the OpenHands agent or Claude Code, Codex, Gemini and any ACP-compatible agent across local, Docker and cloud backends, with automations triggered by schedules and webhooks.

MIT control centre that runs the OpenHands agent or Claude Code, Codex and any ACP agent in Docker and on your infrastructure, with automations from Slack, GitHub and Linear.

Know firstBeta, and its README warns two install routes give the agent full filesystem access.

Licence
MIT
Runs as
npm package, Docker, From source
Platforms
macOS, Linux, Windows (separate guide)
Hosted option
Sold by the maintainers
Last release
v1.20.0, Sep 17, 2026

Codex CLI

OSIOpenAI models with open agent code

OpenAI's Apache-2.0 coding agent that runs locally in your terminal, with a desktop app and IDE extensions, signed in with a ChatGPT plan or an OpenAI API key, so the code is open and the models are OpenAI's.

Apache-2.0 agent that runs locally, with a desktop app and IDE extensions, signed in with a ChatGPT plan or an API key.

Know firstOnly OpenAI's hosted models; no other provider and no local model.

Licence
Apache-2.0
Runs as
CLI, Desktop app, IDE extension for VS Code, Cursor and Windsurf
Platforms
macOS (Apple Silicon and Intel), Linux (x86_64 and arm64), Windows
Hosted option
Sold by the maintainers
Last release
rust-v0.155.0, Sep 17, 2026

Gemini CLI

OSIA free tier on a Google account

Google's Apache-2.0 terminal agent for Gemini models with a free tier of 1,000 requests a day on a personal Google account, built-in search grounding, file and shell tools, MCP support, checkpointing and a GitHub Action.

Apache-2.0, with 1,000 requests a day on a personal Google account by its README, search grounding, shell and file tools, MCP and a GitHub Action.

Know firstOnly Google's hosted Gemini models; no other provider and no local model.

Licence
Apache-2.0
Runs as
CLI, VS Code companion, GitHub Action
Platforms
macOS and Linux (Homebrew, MacPorts), Anywhere Node.js runs (npm)
Hosted option
Sold by the maintainers
Last release
v0.60.0, Sep 15, 2026

How to choose

The questions that settle it, in the order they usually come up.

  1. Must the model run on your own machine?

    Qwen Code, Crush, goose, gptme and Cline document local models. Codex CLI and Gemini CLI cannot; OpenCode's README does not say.

  2. Do you want to keep using Claude models?

    Cline, Crush, Qwen Code, gptme and goose list Anthropic; goose and gptme accept an existing Claude subscription; Zed and OpenHands can host Claude Code itself.

  3. Do you need a read-only or planning mode?

    OpenCode's plan agent, Cline's Plan mode, Qwen Code's plan mode, or Crush's permission prompts on every call.

  4. Does the licence have to be OSI-approved?

    All except Crush, which is under the Functional Source License until each version converts to MIT after two years.

Where Claude Code is still the better choice

Claude Code, in the vendor's own words, is a tool to "hand Claude a bug fix, test, or multi-day migration" and "steer and review from your terminal, IDE, Slack, or web", running in the terminal alongside your IDE with extensions for VS Code and JetBrains, by its own description. claude.com. The cases below are where that still wins.

  • You want Claude models with the agent built around them by Anthropic, in the terminal, the IDE, Slack and the web, as one supported product.
  • You want multi-day tasks steered from Slack or the web with no infrastructure to run; OpenHands offers that shape but on your own servers.
  • You want no provider decisions at all. Every open option here except Codex CLI and Gemini CLI asks you to choose a model.
  • You want one vendor accountable for the agent and the model together.

How this page was checked

Numbers from GitHub, dated

Stars, licence, last commit and last release are read from the GitHub API by a script every week and carry the date they were read. Nobody types them.

Claims from the README

What each project does is written from its own README and LICENSE, read in full on the date shown, and phrased as the project's claim. The sources are listed at the end.

What is never said

That a project is faster, better or cheaper than Claude Code. A price for anyone. A user count. A roadmap. If a fact is not on this page, it was not in the source.

OSI Open source (OSI licence)
The code, and the weights where the project is a model, carry a licence on the OSI approved list.
Source available Source available
The code is public, and the licence limits what you may do with it. Read the LICENSE file before commercial use.
Open weights Open weights
The model weights can be downloaded and run. The training data or code is closed, or the weights carry a restriction the code does not.

Questions people ask

What is the best open-source alternative to Claude Code?

OpenCode (MIT) for a terminal agent with a built-in read-only planning mode and the largest community. Qwen Code (Apache-2.0) for the same workflow with OpenAI, Anthropic, Gemini, Qwen or local models switched at runtime. Crush for the widest provider list with local models, under a licence that turns MIT after two years. goose (Apache-2.0) for a desktop app plus CLI under Linux Foundation governance.

Which Claude Code alternatives run local models?

Qwen Code through Ollama or vLLM, Crush through llama.cpp, Ollama, LM Studio and others, gptme through llama.cpp, goose through Ollama, and Cline through Ollama or LM Studio. OpenCode's README does not state its providers. Codex CLI and Gemini CLI use only their vendor's hosted models.

Is Codex CLI an open-source Claude Code alternative?

The agent is Apache-2.0 and runs locally, so the code is open to read and change. It signs in only with a ChatGPT plan or an OpenAI API key and offers no other provider or local model, so it replaces Claude Code with the same vendor-tied shape from OpenAI. Gemini CLI is the same shape from Google, with a free tier.

Can I keep using Claude models with an open-source agent?

Yes. Cline, Crush, Qwen Code, gptme and goose list Anthropic among their providers, and goose and gptme can sign in with an existing Claude subscription. Zed runs Claude Code itself inside the editor over the Agent Client Protocol. The agent becomes open source; the model stays your choice.

Which one has a planning or read-only mode?

OpenCode ships a plan agent that denies file edits by default and asks before running commands, switched with the Tab key. Cline has Plan and Act modes with approval on every edit and command. Qwen Code lists a plan mode. Crush asks permission before every tool call by default and allows rules in a config file.

Are these licences all OSI-approved?

OpenCode (MIT), Qwen Code, Codex CLI, Gemini CLI, goose and Cline (Apache-2.0), gptme and OpenHands (MIT) are. Crush is not yet: it is under the Functional Source License, which forbids competing commercial use until each version converts to MIT two years after release, so this site labels Crush source available.

Which is the most used?

By GitHub stars on the date printed in each facts panel, OpenCode had the most of any project in this directory, followed by Codex CLI and Gemini CLI. Stars are shown as a dated fact and were not used to rank this page; licence and fit were.

Sources

  1. Claude Code product page, the vendor's own description, read September 17, 2026
  2. OpenCode README, read September 17, 2026
  3. Qwen Code README, read September 17, 2026
  4. Crush README and LICENSE, read September 17, 2026
  5. goose README, read September 17, 2026
  6. gptme README, read September 17, 2026
  7. Codex CLI README, read September 17, 2026
  8. Gemini CLI README, read September 17, 2026

Running one of these inside your own environment, with your own data and your own security rules, is the kind of work Reveneau does. Read how a forward deployed engagement works.