The open source alternatives to Claude Code are OpenCode (MIT) and Codex CLI, Cline, goose and Aider (all Apache 2.0). Claude Code itself is not open source: its repository carries an all rights reserved notice. All five alternatives can run on a model on your own machine, through Ollama or their own settings, which is the main reason people switch. Gemini CLI is Apache 2.0 too, but its README now points free individual use to a different tool, and Continue's repository is read-only and no longer actively maintained. Swapping the agent does not swap the model: each one uses whichever model you give it, so the answers are only as good as that model. This page quotes no speed or quality figure, because we have not measured any of these agents.
| Agent | Licence | Where it runs | Models |
|---|---|---|---|
| Claude Code | All rights reserved (Anthropic) | Terminal, and the Code tab of the Claude desktop app | Claude models |
| OpenCode | MIT | Terminal, and a desktop app in beta for Mac | Finds a running Ollama by itself |
| Codex CLI | Apache 2.0 | Terminal | Your ChatGPT plan, or a local Ollama model with its oss flag |
| Cline | Apache 2.0 | Terminal, VS Code, JetBrains, and a desktop app for macOS and Windows | Many providers, and Ollama and LM Studio for local models |
| goose | Apache 2.0 | Desktop app for macOS, Linux and Windows, a command line, and an API | More than 15 providers, Ollama among them |
| Aider | Apache 2.0 | Terminal, and watch mode in your editor | Almost any model, including local models |
None of the repositories above is archived, as read on 19 November 2026. Aider's latest release is v0.86.0, from August 2025, so it has not shipped a release in a while; its repository is not archived and nothing there says it has stopped.
The setup for each, with the context window each one's documentation asks for, is on coding agents on a local model on a Mac. To keep Claude Code itself and swap only the model, see Claude Code with a local model.
Grux AI (MIT) is not a coding agent. It is an agent for your mail, calendar, files and shell on a Mac, and it writes work orders for a coding agent such as Claude Code when you want to change the app itself. For the wider list of open source agents on a Mac, see open source AI agents for macOS.
| Claim | Source |
|---|---|
| Claude Code's repository is all rights reserved | Claude Code LICENSE.md |
| OpenCode is MIT, has a plan and a build agent, and a macOS desktop app in beta | OpenCode README and its repository |
| OpenCode finds a running Ollama and lists its models | OpenCode documentation, providers |
| Codex CLI is Apache 2.0, signs in with a ChatGPT plan, and runs on Ollama with its oss flag | Codex README and Ollama documentation, Codex CLI |
| Cline is Apache 2.0, runs in the terminal, VS Code, JetBrains and a desktop app, and uses Ollama and LM Studio | Cline README |
| goose is Apache 2.0, works with more than 15 providers including Ollama, and is part of the Agentic AI Foundation | goose README |
| Aider is Apache 2.0, connects to local models, commits its changes, and its latest release is v0.86.0 | Aider README and Aider releases |
| Gemini CLI is Apache 2.0, and free individual access moved to Antigravity CLI on 18 June 2026 | Gemini CLI README |
| Continue is read-only and no longer actively maintained | Continue README |
All of these were read on 19 November 2026. Agents change quickly, so check the repository for what it says today.