All posts
Developer Tools·8 min read·Updated 18 Sept 2026

Best Open-Source AI Coding Agents in 2026: OpenCode, Codex CLI, OpenHands and More

Quick answer
The leading open-source AI coding agents in September 2026 are OpenCode (about 208,000 GitHub stars), OpenAI's Codex CLI, Google's Gemini CLI, OpenHands, Cline and Goose. OpenCode and Codex CLI suit the terminal, Cline suits VS Code, and OpenHands suits autonomous tasks in a sandbox. All work with more than one model provider.

The open-source AI coding agents worth using in 2026, ranked by real GitHub data: OpenCode, Codex CLI, Gemini CLI, OpenHands, Cline, Goose and Aider — and which one fits you.

Piyush Jangir
Verified author

Founder of StackPicks. Self-taught builder shipping open-source dev tools, marketing, and curator content since 2019. Based in Mumbai, India. Available on GitHub and LinkedIn.

8 min read
Best Open-Source AI Coding Agents in 2026: OpenCode, Codex CLI, OpenHands and More

Short version: OpenCode is the most-starred open-source coding agent of 2026, with Codex CLI and Gemini CLI close behind. For VS Code, pick Cline. For autonomous work in a sandbox, OpenHands. All numbers below are from the GitHub API on 18 September 2026, which also revealed that two popular agents have moved organisations and one well-known agent has slowed down.

Open-source AI coding agents by GitHub stars, September 2026

Terminal agents

**OpenCode** is an open-source coding agent for the terminal and the clear leader by stars this year. Provider-agnostic, so you can point it at hosted or local models.

**Codex CLI** (Apache-2.0) is OpenAI's open-source agent, with OS-level sandboxing when it runs locally. It can also use a ChatGPT subscription you already pay for.

**Gemini CLI** (Apache-2.0) is Google's open-source agent. Note that for unpaid-tier and Google One users, Google replaced it with Antigravity CLI on 18 June 2026; the code remains open source.

**Goose** (Apache-2.0), now at its new home aaif-goose/goose, is an extensible local agent built around MCP.

**Aider** pioneered git-centric pair programming in the terminal. Still useful; its last code push was in May 2026.

In the editor

**Cline** runs inside VS Code, shows every change as a diff and asks before acting. The friendliest place to start.

Autonomous, in a sandbox

**OpenHands** (MIT), formerly All-Hands-AI, runs an agent in a sandboxed environment and works through tasks end to end. Suited to delegating well-scoped issues.

Which open-source coding agent fits which workflow

How to pick

  1. Pick the surface.

- Terminal: OpenCode or Codex CLI.

- VS Code: Cline.

- Hands-off: OpenHands.

  1. Pick the model route.

- Existing subscription: Codex CLI can use ChatGPT plans.

- Your own key: any of them.

- Fully local: OpenCode, Cline or Goose with Ollama.

  1. Keep skills portable.

- Most read SKILL.md, so the same skills follow you between agents.

Want a hosted agent instead? Our Claude Code vs Codex comparison covers the paid options.

Frequently asked questions

What is the most popular open-source coding agent?+

By GitHub stars in September 2026, OpenCode, with about 208,000, followed by OpenAI's Codex CLI at about 125,000 and Google's Gemini CLI at about 107,000. Stars measure attention rather than quality, so treat them as a shortlist. The right agent depends on where you work, the terminal, VS Code or a sandbox, and which models you want to use.

Are open-source coding agents free?+

The agent software is free; the model usually is not. Most open-source agents connect to a hosted model through your own API key, so you pay the provider per token. Several also run against local models through Ollama, which makes the whole setup free at the cost of lower quality on large tasks. Some, like Codex CLI, can also use a subscription you already have.

Is Aider still maintained?+

Aider remains available and widely used, with about 49,000 stars, but its most recent code push at the time of writing was in May 2026, slower than most agents in this list. It still works well for git-centric pair programming in the terminal. If you are choosing today, weigh that maintenance pace against the more actively developed options.

What happened to Goose and OpenHands?+

Both moved to new organisations. Goose, originally from Block, now lives at aaif-goose/goose, and OpenHands, formerly All-Hands-AI/OpenHands, is now OpenHands/OpenHands. GitHub redirects the old URLs, but directories and blog posts that still use the old names can make them look abandoned when they are actively developed.

Which open-source coding agent is best for beginners?+

Cline, because it runs inside VS Code, shows every proposed change as a diff and asks for approval before editing files or running commands. That makes it easy to see what the agent is doing and to learn from it. Terminal agents such as OpenCode and Codex CLI are powerful but assume you are comfortable reviewing changes in git.

More in Developer Tools

Best Open-Source AI Coding Agents in 2026: OpenCode, Codex CLI, OpenHands and More — StackPicks — StackPicks