# Claude Code vs Codex CLI (2026)

> Claude Code and Codex CLI side by side from each vendor's docs: plans, limits, MCP, platforms and licence. No made-up benchmarks, and how to run both.

Source: https://shuriken.sh/compare/claude-code-vs-codex

Claude Code (Anthropic) and Codex CLI (OpenAI) are both strong terminal coding agents that read your repository, edit files and run commands. For most people the deciding factor is which plan they already pay for and how its limits fit their day, and you can run both.

By Shuriken Updated 27 October 2026 6 min read

**Contents**

We make Shuriken. We tried to be fair; corrections welcome at office@shuriken.sh.

## Quick answer #

Claude Code vs Codex is mostly decided by the subscription you already have. Claude Code (Anthropic) signs in with a Claude Pro, Max, Team or Enterprise plan; Codex CLI (OpenAI) signs in with a ChatGPT plan, Free included. Both run in your terminal, read your repository, edit files and run commands. What you'll feel is whose limits fit your day, and you can run both.

## At a glance #

Every cell comes from the vendor's own docs or repository, read on 22 October 2026.

| | Claude Code | Codex CLI |
| --- | --- | --- |
| Made by | Anthropic | OpenAI |
| Licence | Proprietary: ["All rights reserved"](https://github.com/anthropics/claude-code/blob/main/LICENSE.md), use under Anthropic's Commercial Terms | Open source, [Apache-2.0](https://github.com/openai/codex) |
| Sign in with | Claude [Pro, Max, Team, Enterprise or a Console account](https://code.claude.com/docs/en/setup); the free claude.ai plan doesn't include it | A ChatGPT plan: OpenAI's [pricing page](https://learn.chatgpt.com/docs/pricing) includes Codex in Free, Go, Plus, Pro, Business, Edu and Enterprise. Or an [API key with extra setup](https://github.com/openai/codex) |
| Subscription limits | A [rolling five-hour session window](https://claude.com/pricing); paid plans add weekly limits | Plus: messages per [five-hour period](https://learn.chatgpt.com/docs/pricing), weekly limits may apply. Pro: "currently no five-hour limit" |
| Past the limit | Usage credits on paid plans | Plus and Pro can buy credits |
| MCP servers | Yes: [~/.claude.json or a project's .mcp.json](https://code.claude.com/docs/en/mcp) | Yes: [~/.codex/config.toml](https://learn.chatgpt.com/docs/extend/mcp?surface=cli), [mcp_servers.<name>] , stdio and HTTP with OAuth |
| Platforms | [macOS 13+, Windows 10 1809+ (native or WSL), Ubuntu 20.04+, Debian 10+, Alpine 3.19+](https://code.claude.com/docs/en/setup) | [macOS and Linux](https://github.com/openai/codex) binaries; Windows via a PowerShell install script, with Windows and WSL pages in the docs |
| Install | curl -fsSL https://claude.ai/install.sh | bash , Homebrew, WinGet, Debian, Fedora and Alpine package repositories, npm | [curl -fsSL https://chatgpt.com/codex/install.sh | sh](https://learn.chatgpt.com/docs/codex/cli), npm, Homebrew |
| Desktop app | Claude Desktop's Code tab (macOS, Windows, Linux) | Codex inside the ChatGPT desktop app (macOS, Windows, Linux) |

## Why there are no benchmarks on this page #

We left them out on purpose. A ten-task chart would date with the next model either vendor ships, it would depend on your repository's size and language and on how you prompt, and we sell a harness for both, so you'd be right to doubt our choice of tasks.

Run the same task in both, on your own code, and compare the diffs. It takes ten minutes, and it's the only result that applies to you. (Shuriken makes this easy, see the end of this page.)

## What Claude Code does well #

- Subagents, hooks, skills, plugins, project memory files and MCP servers give you a lot of control over how it works. Shuriken can install, enable and update Claude Code plugins per project, because so many people rely on them.
- Native Windows, WSL, macOS and several Linux distributions are all first-class in the docs, with signed package repositories for Debian, Fedora and Alpine.
- One Claude subscription covers the CLI, the Desktop app's Code tab and Anthropic's cloud scheduled tasks.
- The limits are a five-hour session window plus a weekly limit: annoying when you hit them, but predictable ([how the 5-hour window works](https://shuriken.sh/guides/claude-5-hour-limit-explained)).

## What Codex does well #

- The source is open, under Apache-2.0. You can read exactly what the agent does, file issues against the code and build it yourself.
- MCP servers live in ~/.codex/config.toml, and OpenAI's docs say "The ChatGPT desktop app, Codex CLI, and IDE extension share this configuration."
- Streamable HTTP servers sign in with OAuth, including dynamic client registration, or with bearer tokens; codex mcp login <server-name> starts the OAuth sign-in.
- ChatGPT Pro has no five-hour cap right now. OpenAI's pricing page says "Pro plans currently have no five-hour limit", which matters if your work comes in long bursts ([Codex usage limits](https://shuriken.sh/guides/codex-usage-limits) has the details).

Shuriken runs Claude Code, Codex, Gemini CLI and 64 more agents side by side, with your own sign-ins.

[Download](https://shuriken.sh/download)

## Where they differ in practice #

### The limit you'll actually hit #

Claude's limit is a rolling five-hour window plus a weekly cap, and a busy day usually hits the window first. ChatGPT Plus counts messages per model in each five-hour period; OpenAI publishes those figures as estimates, "not fixed message limits", and adds that weekly limits may also apply. ChatGPT Pro currently has no five-hour limit at all, and OpenAI's page lists no separate weekly figure for Pro. Which shape hurts less depends on how your work spreads over the day and the week; the plans themselves are compared in [Claude Max vs ChatGPT Pro](https://shuriken.sh/compare/claude-max-vs-chatgpt-pro-for-coding).

### Two config formats #

Claude Code reads JSON (~/.claude.json, .mcp.json), and claude mcp add --transport http notion https://mcp.notion.com/mcp adds a server from the command line. Codex reads TOML (~/.codex/config.toml, one [mcp_servers.<name>] table per server), and its equivalent is codex mcp add context7 -- npx -y @upstash/context7-mcp. Using both by hand, you keep two lists of MCP servers in step and sign in to Linear, Notion or GitHub twice.

### Openness #

Codex's source is public; Claude Code's licence says "All rights reserved". For some teams that's a policy question. For most individual developers it changes little day to day.

## Which should you choose? #

None of these is about which model is smarter this month.

| If | Start with |
| --- | --- |
| You already pay for Claude Pro or Max | Claude Code. It's included, and your limits are already there |
| You already pay for ChatGPT Plus or Pro | Codex, for the same reason |
| You want to read the agent's source, or your company requires open source | Codex |
| You're on native Windows and don't want WSL | Both have Windows paths, but Claude Code's docs treat native Windows as a first-class setup with its own install commands and a WinGet package. For Codex, [Codex CLI on Windows](https://shuriken.sh/guides/codex-cli-on-windows) covers its native sandbox and when WSL still fits |
| You rely on plugins, hooks and subagents you've already built | Claude Code; moving those over is real work |
| Your work comes in long bursts that hit a five-hour cap | ChatGPT Pro, which currently has no five-hour limit |
| Neither fits | Our list of [Claude Code alternatives](https://shuriken.sh/compare/claude-code-alternatives), open-source agents included |
| You can't decide | Both, for a week of real tasks; keep the one you reached for more often |

## Pricing #

Both agents come with their vendor's plans at no extra cost. Prices as published on 22 October 2026, in US dollars.

| | Price |
| --- | --- |
| Claude | [Pro is $20 a month ($17 billed yearly); Max starts at $100 a month](https://claude.com/pricing), with a 5x and a 20x tier |
| ChatGPT | [Plus is $20 a month; Pro starts at $100 a month](https://learn.chatgpt.com/docs/pricing), with plans at $100, $200 or $500. Codex is also included in the Free and Go ($8 a month) plans |
| API keys | Both agents can run on pay-as-you-go API keys instead, billed at API rates |

## Using them together #

In Shuriken, one project can hold a Claude Code chat and a Codex chat side by side, each on its own branch in its own git worktree, so they never edit the same files under each other.

- Add an MCP server once in [Global MCPs](https://shuriken.sh/features/global-mcps) and every Claude Code and Codex chat gets it, with no .mcp.json and config.toml to keep in step. You sign in to each server once, because the sign-in belongs to the server, not to your AI account.
- Claude Code chats run on your Claude sources, Codex chats on your ChatGPT sign-ins and OpenAI keys. When an account reaches your switch point (99% by default, adjustable from 50% to 100%), its chats move to another source you added for that agent and keep going. A Claude Code chat never turns into a Codex chat.
- For the ten-minute comparison, give the same prompt to a Claude Code chat and a Codex chat, compare both diffs in Changes, and finish the one you like.

Shuriken also runs Gemini CLI, Copilot, OpenCode and the rest of its [67 coding agents](https://shuriken.sh/features/coding-agents).

If you pay for both, [download Shuriken](https://shuriken.sh/download) and add a source for each.

Try the free tools: [Claude limit reset tracker](https://shuriken.sh/tools/limit-resets/claude) · [Codex limit reset tracker](https://shuriken.sh/tools/limit-resets/codex)

Share

[X](https://x.com/intent/post?url=https%3A%2F%2Fshuriken.sh%2Fcompare%2Fclaude-code-vs-codex&text=Claude%20Code%20vs%20Codex%20CLI%20(2026))[LinkedIn](https://www.linkedin.com/sharing/share-offsite/?url=https%3A%2F%2Fshuriken.sh%2Fcompare%2Fclaude-code-vs-codex)[Hacker News](https://news.ycombinator.com/submitlink?u=https%3A%2F%2Fshuriken.sh%2Fcompare%2Fclaude-code-vs-codex&t=Claude%20Code%20vs%20Codex%20CLI%20(2026))[Reddit](https://www.reddit.com/submit?url=https%3A%2F%2Fshuriken.sh%2Fcompare%2Fclaude-code-vs-codex&title=Claude%20Code%20vs%20Codex%20CLI%20(2026))[E-mail](mailto:?subject=Claude%20Code%20vs%20Codex%20CLI%20(2026)&body=https%3A%2F%2Fshuriken.sh%2Fcompare%2Fclaude-code-vs-codex)

## Sources

- [Claude Code advanced setup: system requirements and authentication](https://code.claude.com/docs/en/setup) (accessed 22 October 2026)
- [Connect Claude Code to tools via MCP (Claude Code docs)](https://code.claude.com/docs/en/mcp) (accessed 22 October 2026)
- [Claude Code licence (GitHub)](https://github.com/anthropics/claude-code/blob/main/LICENSE.md) (accessed 22 October 2026)
- [Claude plans and pricing](https://claude.com/pricing) (accessed 22 October 2026)
- [Codex CLI README (GitHub)](https://github.com/openai/codex) (accessed 22 October 2026)
- [Codex CLI (OpenAI docs)](https://learn.chatgpt.com/docs/codex/cli) (accessed 22 October 2026)
- [Codex pricing and usage limits (OpenAI docs)](https://learn.chatgpt.com/docs/pricing) (accessed 22 October 2026)
- [Model Context Protocol in Codex (OpenAI docs)](https://learn.chatgpt.com/docs/extend/mcp?surface=cli) (accessed 22 October 2026)

## Frequently asked questions

**Which is better, Claude Code or Codex?**

Neither wins everywhere, and the answer changes with each model release and with your codebase. Try both on the same task in your own repository and compare the diffs; often the plan you already pay for decides.

**Can one subscription cover both?**

No. Claude Code signs in with a Claude plan (Pro, Max, Team or Enterprise) or an Anthropic Console account. Codex signs in with a ChatGPT plan or an OpenAI API key.

**Can I switch between Claude Code and Codex in one project?**

Yes. In Shuriken, each chat picks its agent, and one project can hold both. A chat keeps its agent, so start the next chat with the other one when you want to switch. Both see the same MCP servers from Global MCPs.

**Do both support MCP servers?**

Yes. Claude Code keeps its servers in ~/.claude.json or a project's .mcp.json. Codex keeps them in ~/.codex/config.toml under [mcp_servers]. Shuriken keeps one list and hands it to both.

**Do both run on Windows?**

Claude Code supports native Windows 10 and 11 as well as WSL. Codex has a PowerShell install script and Windows and WSL pages in its docs. Both run on macOS and Linux.

Every coding agent

67 coding agents, one harness.

Run Claude Code, Codex, Gemini CLI and the rest on your own computers, with the sign-ins you already have.

[Download](https://shuriken.sh/download)

[Other platforms](https://shuriken.sh/download#main)

## Keep reading

- [Claude Code and Codex in one project: Story 27 Oct 2026 3 min read How to use Claude Code and Codex together on one project: a chat per agent, one set of MCP servers for both, and each agent on its own sources.](https://shuriken.sh/blog/claude-and-codex-together)
- [Shuriken vs the Codex app (2026): Comparison 27 Oct 2026 6 min read The Codex app is OpenAI's own, with Cloud tasks and schedules. Shuriken runs Codex beside Claude Code and 65 more agents, across your ChatGPT accounts.](https://shuriken.sh/compare/codex-app)
- [Cursor vs Claude Code: editor or terminal agent?: Comparison 27 Oct 2026 10 min read Cursor is an editor with an agent and a weekly usage pool; Claude Code is Anthropic's agent on 5-hour and weekly limits. Models, rules, MCP, cloud.](https://shuriken.sh/compare/cursor-vs-claude-code)
- [AGENTS.md vs CLAUDE.md: one file for every agent?: Comparison 27 Oct 2026 6 min read AGENTS.md vs CLAUDE.md: Codex reads AGENTS.md, Claude Code reads it when there is no CLAUDE.md or through @AGENTS.md, Gemini CLI once you list it.](https://shuriken.sh/compare/agents-md-vs-claude-md)
- [Shuriken vs Cursor agents (2026): Comparison 27 Oct 2026 5 min read Cursor's cloud agents run in Cursor's VMs, billed to a Cursor plan. Shuriken runs the agents you pick on your own machines, on your own plans. Compared.](https://shuriken.sh/compare/cursor)
- [Gemini CLI alternatives after the June 2026 change: Comparison 27 Oct 2026 7 min read Gemini CLI alternatives by sign-in: Antigravity CLI for a personal Google account, a paid key to keep Gemini CLI, or Claude Code, Codex and Qwen Code.](https://shuriken.sh/compare/gemini-cli-alternatives)
- [Gemini CLI vs Antigravity CLI: which one can you still use?: Comparison 27 Oct 2026 8 min read Gemini CLI vs Antigravity CLI: since 18 June 2026 a personal Google account gets agy; a Code Assist licence or a paid Gemini API key keeps Gemini CLI.](https://shuriken.sh/compare/gemini-cli-vs-antigravity-cli)
- [Shuriken and OpenCode: use them together: Comparison 27 Oct 2026 6 min read OpenCode is an open-source coding agent with its own desktop app. Shuriken is a harness that runs it next to Claude Code and Codex, on your machines.](https://shuriken.sh/compare/opencode)

## Free tools

- [Claude limit reset tracker](https://shuriken.sh/tools/limit-resets/claude)
- [Codex limit reset tracker](https://shuriken.sh/tools/limit-resets/codex)
