Claude vs ChatGPT for Coding (October 2026): Claude Code vs Codex, Plans and Prices
Disclosure: this comparison contains no affiliate links. Anthropic and OpenAI do not run affiliate programs for their consumer subscriptions, so there is nothing here for us to earn a commission on. Our affiliate disclosure explains how the rest of the site is funded. Editorial placement is decided on merit and is not for sale.
By Lennit Herrera, founder and editor, AI Tool Stack Reviews · Last updated October 27, 2026
The verdict: on the published evidence, Claude Pro at $20 a month ($17 on annual billing) is the stronger pick for a developer who wants a coding agent in the terminal. It includes Claude Code and the Opus 5.5 model, which sits at the top of Artificial Analysis’s independent Intelligence Index (58, against 53 for GPT-6 Astra). ChatGPT Plus at $20 is the better pick if cost per task matters more than the last few points of capability: Codex is included in the plan, and Artificial Analysis lists GPT-6.1 Sol at roughly an eighth of Opus 5.5’s cost per task on the same index. Both are close enough that the deciding factors are usage limits, which differ in how they are published, and the editor or CI setup you already have.
Prices, plan terms and model specifications were read on each company’s own pricing page, model documentation and help centre on October 27, 2026. The independent figure on this page comes from Artificial Analysis’s public leaderboard, read the same day. Since our first read on October 2, Anthropic has added Claude Haiku 5.5 and OpenAI has added GPT-6.1 Terra, which reached Codex on October 26; both are in the tables below.

On this page
- The short list
- Comparison table: price, agent, models, limits
- How we compared them
- Claude: Claude Code and the Pro plan
- ChatGPT: Codex and the Plus plan
- Usage limits: the part that decides it
- API prices side by side
- What the benchmarks say, and who ran them
- Team and business plans
- Who each one is right for
- What this comparison cannot tell you
- Frequently asked questions
The short list
- Claude Pro with Claude Code — for the developer who wants the highest-ranked model and a mature terminal agent, and will pay for it in usage-limit uncertainty.
- ChatGPT Plus with Codex — for the developer who wants published usage ranges, cheaper models in the lineup and an open-source CLI.
- The free tiers — Claude Free does not include Claude Code at all; ChatGPT Free and Go include Codex with a small model, in the desktop app, subject to rollout.
- API key instead of a subscription — both vendors support it for CI and heavy automation, and both bill at the token prices in the API section.
Comparison table
| Claude Pro | ChatGPT Plus | |
|---|---|---|
| Price | $20 monthly, or $17 a month on annual billing ($200 up front) | $20 a month |
| Coding agent included | Claude Code | Codex |
| Where the agent runs | Terminal, VS Code, JetBrains, desktop app, web | Web, CLI, IDE extension, iOS |
| Flagship model on the plan | Opus 5.5 (Fable 5.1 only via usage credits) | GPT-6.1 Sol and GPT-6 Luna (Astra appears in the limits table) |
| Published usage numbers | None found; limits “apply” and are shared with chat | Estimated local messages per five hours, by model |
| Free tier for the agent | No (Claude Code is “No” on the Free column) | Yes, GPT-6 Luna in the desktop app, subject to rollout |
| Step up | Max, from $100 a month (5x or 20x Pro usage) | Pro, $100, $200 or $500 a month |
| Context window (API) | 1M tokens, no long-context surcharge | 1,050,000 for GPT-6.1 Sol; input above 272K tokens costs 2x, output 1.5x |
How we compared them
We compared two products against their vendors’ own disclosure pages on October 27, 2026: Claude Code on Anthropic’s Pro and Max plans, and Codex on OpenAI’s ChatGPT plans. That meant reading 11 plan tiers (Claude Free, Pro, Max, Team and Enterprise; ChatGPT Free, Go, Plus, Pro, Business and Enterprise) and the API price lists for nine models: Claude Fable 5.1, Opus 5.5, Sonnet 5.5, Haiku 5.5 and Haiku 4.5, and GPT-6 Astra, GPT-6.1 Sol, GPT-6.1 Terra and GPT-6 Luna. We also read both vendors’ product documentation for the agents themselves, the Opus 5.5 launch post, and Artificial Analysis’s public leaderboard.
We do not test software ourselves. Where a performance figure appears, it comes from a named source and is linked, and we say who ran it. Where a vendor ran the benchmark, we say that too, because a vendor-run benchmark is a claim, not a measurement we can vouch for. Nothing on this page is a first-hand impression of either product.
Claude: Claude Code and the Pro plan
Claude Code is Anthropic’s coding agent. Anthropic’s overview describes it as a tool that “reads your codebase, edits files, runs commands, and integrates with your development tools,” available in the terminal, in IDE extensions, in a desktop app and in the browser. It is included in Pro and Max, and Anthropic’s plan comparison marks it “No” on the Free plan.
| Starting price | $20 monthly or $17 a month annual (Pro); Max from $100 a month |
| Free tier | Claude Free exists, without Claude Code |
| Platforms | Terminal (macOS, Linux, Windows), VS Code and forks, JetBrains, desktop app, web, mobile app |
| Notable limit | Usage is shared with Claude chat, and no message counts are published |
Why Claude Code?
The case for it is the model underneath and the amount of scaffolding around it. Anthropic’s models overview lists Claude Opus 5.5 as the model “for long-running agentic coding and knowledge work,” with a 1M-token context window, 128K tokens of maximum output and a June 2026 knowledge cutoff. The agent itself supports a project instruction file (CLAUDE.md), which it can read alongside an existing AGENTS.md, plus subagents, hooks, MCP connections, reusable skills, scheduled routines, GitHub Actions and GitLab CI/CD integrations, and an Agent SDK for building your own tools on the same engine. If your team is already writing instructions in AGENTS.md for another agent, that compatibility removes a migration cost.
On the Pro plan Anthropic’s own plan table shows Opus as included and Fable as “usage credits,” meaning the stronger and pricier Fable 5.1 is not part of the flat fee. On Max 5x and Max 20x the same row reads “50% of weekly limits.” Pro and Max also share one usage pool between chat and Claude Code, so a long research conversation in the app spends the same allowance as a coding session in the terminal.
What we like
- The strongest independently ranked model on this page is on the $20 plan.
- One subscription covers the terminal, VS Code, JetBrains, the desktop app and the browser, and the instruction files carry across all of them.
- Reading
AGENTS.mdmeans a repository set up for another agent does not need rewriting. - The full 1M-token window is billed at standard rates on the API, with no long-context premium, per Anthropic’s pricing page.
Watch out for
- No published usage numbers. The pricing page says usage limits apply, and the Pro-and-Max help article says limits are shared across Claude and Claude Code. We found no per-plan message counts, so you cannot estimate in advance how many sessions $20 buys.
- An API key silently overrides your subscription. Anthropic’s help article warns that if an
ANTHROPIC_API_KEYenvironment variable is set, Claude Code uses it “resulting in API usage charges rather than using your subscription’s included usage.” - Going past the limit can turn into metered billing. Anthropic’s options at the cap include usage credits or API credits billed “at standard API rates.” You can decline them and wait for the reset, but you have to know to.
- Fable 5.1 is not in the flat fee on Pro. If a review tells you to use Fable on a $20 plan, check that it means credits.
Best for: developers who want the top-ranked model and a terminal-first agent with a deep extension surface. Skip it if: you need predictable, published usage ranges, or you want a free tier for the agent.
For the wider field, including editor-native tools, read our roundup of AI coding assistants, and for the editor most often paired with these models see our Cursor review.
ChatGPT: Codex and the Plus plan
Codex is OpenAI’s coding agent. OpenAI’s pricing page states that “ChatGPT Work and Codex are included in your ChatGPT Free, Go, Plus, Pro, Business, Edu, or Enterprise plan” and that they share usage. Plus lists Codex “on the web, in the CLI, in the IDE extension, and on iOS,” along with cloud-based integrations such as automatic code review and Slack. The Codex command-line tool is published at github.com/openai/codex under the Apache-2.0 license, which GitHub’s repository metadata confirmed on October 2.
| Starting price | $0 (Free), $8 (Go), $20 a month (Plus); Pro from $100 |
| Free tier | Yes: GPT-6 Luna at standard speed in the desktop app, subject to rollout |
| Platforms | Web, CLI, IDE extension, iOS, desktop app |
| Notable limit | The strongest model, GPT-6 Astra, is rationed to an estimated 5 to 45 local messages per five hours on Plus |
Why Codex?
OpenAI is more explicit about what a subscription buys. Its pricing page publishes estimated local messages per five-hour period for Plus and standard Business: GPT-6 Astra 5 to 45, GPT-6.1 Sol 15 to 160, GPT-6 Sol 15 to 150, GPT-6.1 Terra 35 to 285 and GPT-6 Luna 350 to 3,000. It adds that the figures “are not fixed message limits,” that cloud tasks “may use more of your allowance than local messages,” and that weekly limits may also apply. Pro plans “currently have no five-hour limit.” That is still vague, but it is a range you can plan around, and Anthropic does not publish an equivalent.
The model lineup is also cheaper at the low end. GPT-6.1 Sol, which OpenAI’s model page says “delivers near-Astra performance at a lower cost for complex coding, computer use, and professional work,” lists at $2 per million input tokens and $10 per million output tokens on the API. GPT-6 Luna, described as “our most efficient model for focused, high-volume tasks,” lists at $0.10 and $0.50. And OpenAI’s pricing page offers an API-key route for CLI, SDK and IDE use that is billed at API prices, which suits CI.
What we like
- Published usage ranges by model, so you can see what the $20 plan roughly buys before you subscribe.
- A free and an $8 tier that include the agent, which lets you try the workflow before paying $20.
- An Apache-2.0 command-line tool you can read and fork.
- GPT-6.1 Sol and Luna lower the cost of routine tasks, and Artificial Analysis lists Sol at a fraction of the per-task cost of the top Claude entries.
Watch out for
- The top model is heavily rationed on Plus. An estimated 5 to 45 Astra messages per five hours means Astra is a spot-check tool at $20, not a daily driver. Pro’s $500 tier adds “Astra Ultrafast” access.
- Speed modes spend allowance faster. OpenAI states Fast mode uses 2.5x included usage and Astra Ultrafast uses 8x, relative to Standard for the same model.
- The model lineup is moving. GPT-5.5 was retired from Codex sign-in on October 14, 2026, and GPT-6.1 Terra arrived in Codex on October 26. Check the pricing page for the current names before you rely on any model on this page.
- The free and Go tiers are conditional. The page says the desktop-app access is “subject to rollout,” so it may not be available to every account.
Best for: developers who want to see usage estimates up front, prefer an open-source CLI, or want a cheaper model for everyday work. Skip it if: you specifically need the highest-ranked model for most of your sessions on a $20 budget.
If you are weighing ChatGPT’s wider assistant features rather than the agent, see our three-way comparison of ChatGPT, Claude and Gemini, our Gemini vs ChatGPT page and our list of ChatGPT alternatives. For a GitHub-native option, read our GitHub Copilot review.
Usage limits: the part that decides it
Two $20 plans with similar names are not the same purchase, and the difference is not the model, it is how much of it you get and how clearly you are told. OpenAI publishes ranges. For Plus, the strongest model gets 5 to 45 local messages per five hours, the mid-tier Sol gets 15 to 160, the new Terra 35 to 285 and the small Luna 350 to 3,000. A sensible reading is that OpenAI expects Plus users to run the cheaper models for most work and reach for Astra selectively.
Anthropic publishes the plan structure and no counts. Its Opus 5.5 launch post says Anthropic is “increasing five-hour usage limits on Pro, Max, Team, and seat-based Enterprise plans,” and that subscription users get a saveable rate-limit reset, but it does not give the new numbers. What Anthropic does document is what happens at the cap: you can enable usage credits, switch to API credits, move up to Max 5x, or wait for the reset.
The practical consequence is that you cannot compare the two plans on included work by reading the vendors’ pages. You can compare the escalation paths. Past $20, Claude goes to Max from $100 a month, with a choice of 5x or 20x Pro usage. ChatGPT goes to Pro at $100, $200 or $500, and for Plus and Business users OpenAI says additional ChatGPT credits can extend usage. If you routinely hit a cap on either, the sensible comparison is the $100 tier on each side, not the $20 one.
API prices side by side
Many developers end up on the API, either for CI or because a subscription cap got in the way. These are list prices per million tokens, from Anthropic’s pricing page and OpenAI’s pricing page, read on October 27, 2026. Haiku 5.5’s prices apply to prompts up to 100K tokens; above that it lists $0.50, $0.05 and $2.50. Haiku 4.5 is now listed as a legacy model.
| Model | Input | Cached input | Output |
|---|---|---|---|
| Claude Fable 5.1 | $10 | $0.25 | $50 |
| Claude Opus 5.5 | $4 | $0.20 | $20 |
| Claude Sonnet 5.5 | $2 | $0.10 | $10 |
| Claude Haiku 5.5 | $0.10 | $0.01 | $0.50 |
| Claude Haiku 4.5 | $1 | $0.10 | $5 |
| GPT-6 Astra | $10 | $1 | $50 |
| GPT-6.1 Sol | $2 | $0.10 | $10 |
| GPT-6.1 Terra | $1 | $0.05 | $5 |
| GPT-6 Luna | $0.10 | $0.01 | $0.50 |

Three things in this table are easy to miss. First, the per-token prices on the Claude side are not directly comparable to OpenAI’s, because Anthropic states that Claude 4.7 and later models use a tokenizer that “produces approximately 30% more tokens for the same text.” Second, the context rules differ: Anthropic charges the same per-token rate across the full 1M window, while OpenAI’s GPT-6.1 Sol page says prompts above 272K input tokens “are priced at 2x input and cache rates,” and its pricing page lists output on those prompts at 1.5x. Third, cache reads matter more than the headline input price for agent work, which re-sends the same context on every step. Anthropic’s launch post says cache reads “make up the majority of agentic and coding work costs,” and Opus 5.5’s $0.20 cache rate compares with $0.10 for both Sonnet 5.5 and Sol.
As illustrative arithmetic only, ignoring caching and tokenizer differences, one pass that sends 200,000 input tokens and returns 20,000 output tokens costs about $1.20 on Opus 5.5, $0.60 on Sonnet 5.5, $0.60 on GPT-6.1 Sol, $3.00 on either Fable 5.1 or GPT-6 Astra, and $0.03 on GPT-6 Luna. Real agent sessions make many such passes and vary by model effort setting, which is why the per-task numbers in the next section are more useful than per-token prices.
What the benchmarks say, and who ran them
This is the section most comparison pages overstate, so it is worth being exact about provenance.
The independent figure. Artificial Analysis’s public leaderboard, re-read October 27 with every row below unchanged since October 2, ranks models on its Intelligence Index (version 4.3, which the page says includes Terminal-Bench 4.0 and AutomationBench-AA). That is a general capability index, not a coding-only score, so treat it as a proxy. The relevant rows, with the leaderboard’s own cost-per-task column:
| Model (effort setting) | Intelligence Index | Cost per task |
|---|---|---|
| Claude Opus 5.5 (max) | 58 | $5.98 |
| Claude Opus 5.5 (high) | 54 | $1.82 |
| Claude Fable 5.1 (max) | 53 | $7.63 |
| GPT-6 Astra (max) | 53 | $3.26 |
| GPT-6.1 Sol (max) | 52 | $0.72 |
| GPT-6.1 Sol (xhigh) | 51 | $0.39 |
| GPT-6.1 Sol (high) | 50 | $0.32 |
Read it this way. Opus 5.5 at maximum effort leads the board, five points ahead of Astra. But GPT-6.1 Sol at maximum effort is one point below both Astra and Fable 5.1, at a listed $0.72 against $3.26 and $7.63. The leaderboard labels the Claude entries “with fallback,” a reference to Anthropic’s safeguard routing that Anthropic’s launch post also mentions. We have not verified how Artificial Analysis computes its cost-per-task column, so use the ratios as a rough guide rather than a bill.
The vendor-run figures. Anthropic’s Opus 5.5 announcement (September 22, 2026) reports three agentic-coding results. On FrontierCode v1.1, at default (medium) effort, Opus 5.5 scores 54.6%, ahead of GPT-6 Astra’s top score of 53.3%, “for about a fifth of the cost per task.” On CursorBench 4.0 it scores 52.5% at default effort against 41.7% for GPT-5.6 Sol’s top score. On Terminal-Bench 4.0 it “matches GPT-6 Astra at about 40% of the cost.” Anthropic states that the GPT-6 Astra and GPT-5.6 Sol figures are “as reported by OpenAI.”
Two cautions apply. These are Anthropic’s own runs against OpenAI’s self-reported numbers, and they pre-date GPT-6.1 Sol, which is a newer, cheaper OpenAI model than any of the GPT figures Anthropic compares against. And Anthropic itself writes that “at these levels of capability we’ve found that benchmark margins have become a less reliable guide to real-world differences.” We take that caution at face value. We could not read OpenAI’s own launch post for Sol, because openai.com refuses automated fetches, so no OpenAI-run benchmark figure appears on this page and we did not quote second-hand summaries of one.
Our reading: the evidence supports “Claude’s top model leads, OpenAI’s newest model is much cheaper per task for slightly less,” and does not support a claim that either company’s agent writes better code than the other’s in your repository.
Team and business plans
For teams, the plan structures differ more than the models do. Anthropic’s Team plan has a standard seat at $20 per seat per month on annual billing ($25 monthly) and a premium seat at $100 ($125 monthly) with “5x more usage than standard seats”; Claude Code is part of the Team plan, and you can mix seat types. Enterprise is $20 per seat per month billed annually plus usage at API rates, with a 20-seat minimum.
OpenAI’s Business plan is $20 per user per month for two or more users billed annually ($25 monthly), with the same Sol and Luna models as Plus, larger virtual machines for cloud tasks, and credits to extend usage. Enterprise and Edu are sales-led and add priority processing, SCIM, audit logs and data-residency controls. OpenAI also offers an API-key route for shared environments such as CI, with no cloud features like GitHub code review or Slack. A mixed team that wants a few heavy users and many light ones is the case Anthropic’s seat-mixing is built for. A team that wants predictable per-seat estimates is better served by OpenAI’s published ranges.
Who each one is right for
- A solo developer who wants the best-ranked model in the terminal: Claude Pro. Budget for hitting the cap, and decide in advance whether you will pay for credits.
- A developer on a tight budget: start with ChatGPT Free or Go to try Codex with a small model before spending $20. Claude has no equivalent free route for Claude Code.
- A developer who wants an inspectable CLI: Codex. The command-line tool is Apache-2.0 on GitHub. GitHub shows no open-source license on the Claude Code repository, so check its terms before assuming you can fork it.
- A team that runs agents in CI: either, via API key. Compare per-task cost on your own workload; the per-token tables above will mislead you, because of tokenizer differences and caching.
- Someone who hits caps weekly on either plan: compare the $100 tiers directly. Claude Max starts at $100; ChatGPT Pro starts at $100 and has no five-hour limit.
What this comparison cannot tell you
It cannot tell you which agent will produce better code in your language and codebase, because we have not run either on anything and the public benchmarks are mostly vendor-run. It cannot tell you how many sessions $20 buys on Claude, because Anthropic does not publish counts. It cannot tell you how stable the OpenAI lineup will be, because OpenAI has added or retired a model in Codex in each of the last few weeks. And it should not push you to pay for either if your coding help is occasional: a free tier, or the editor-based tools in our coding assistants roundup, may do the job for less.
The honest test is the cheap one. Use the free route on the OpenAI side for a week of real work, then compare it against one month of Claude Pro on the same tasks, and keep whichever one you stop reaching past. That is more reliable than any leaderboard on this page, including the independent one.
Frequently asked questions
Is Claude or ChatGPT better for coding in October 2026?
Neither wins on every measure. Artificial Analysis’s independent Intelligence Index puts Claude Opus 5.5 at the top (58), ahead of GPT-6 Astra (53) and GPT-6.1 Sol (52). OpenAI’s newest model is listed at far lower cost per task. The vendor-run coding benchmarks favor Claude but were published before GPT-6.1 Sol launched, so the picture may shift.
Is Claude Code included in Claude Pro?
Yes. Anthropic’s plan comparison marks Claude Code as included on Pro and Max and not on Free. Usage is shared with Claude chat, so both draw on the same allowance.
Is Codex free?
Partly. OpenAI’s pricing page lists Codex on Free and Go with GPT-6 Luna at standard speed in the desktop app, “subject to rollout.” The fuller experience on the web, in the CLI and in the IDE extension, with GPT-6.1 Sol, starts at Plus for $20 a month.
How much usage do I get on the $20 plans?
On ChatGPT Plus, OpenAI estimates 5 to 45 local messages per five hours on GPT-6 Astra, 15 to 160 on GPT-6.1 Sol, 35 to 285 on GPT-6.1 Terra and 350 to 3,000 on GPT-6 Luna, and says these are not fixed limits. We found no equivalent numbers for Claude Pro, which Anthropic describes only as usage limits shared across Claude and Claude Code.
Can I use my own API key instead of a subscription?
Yes, on both. OpenAI’s pricing page describes an API-key route for CLI, SDK and IDE use that is billed at API prices and lacks cloud features. For Claude Code, an ANTHROPIC_API_KEY environment variable takes priority over your subscription and bills API usage, which Anthropic’s help article warns about.
Which is cheaper for heavy API use?
List prices favor OpenAI’s mid-tier: GPT-6.1 Sol is $2 and $10 per million tokens against $4 and $20 for Opus 5.5. Claude’s tokenizer produces about 30% more tokens for the same text, per Anthropic, so measure on your own workload. Anthropic also charges no premium across its full 1M-token window, while OpenAI charges double for input and 1.5x for output above 272K input tokens on GPT-6.1 Sol.
Do either of these companies pay affiliate commissions?
Not for consumer subscriptions, as far as we can find, which is why this page has no affiliate links. That also means nobody ranking them is paid by them for the recommendation.
The bottom line
In October 2026 the $20 decision comes down to a trade. Claude Pro buys access to the top-ranked model on Artificial Analysis’s index and a terminal agent with a deep extension surface, but with no published usage numbers and a quiet route to metered billing if you are not careful. ChatGPT Plus buys published usage ranges, an open-source CLI and a cheaper model lineup, but the strongest model is rationed hard and the lineup is changing monthly. Neither company’s benchmarks, including the ones above, can tell you which will work better on your code.
If you can only pick one today, pick Claude Pro for model quality and ChatGPT Plus for predictability, and spend a week on the free OpenAI route first so the choice is yours rather than a leaderboard’s.
About the author
Lennit Herrera is the founder and editor of AI Tool Stack Reviews, and builds and audits websites for a living. We do not test products ourselves and we do not publish scores of our own. Prices, limits and model specifications come from the companies’ own pricing pages and documentation, and every performance figure is attributed to a named source and dated. Corrections are welcome through our contact page.
Related reads







