CIOPages

Codex vs Claude Code

Codex and Claude Code are AI coding agents that read a codebase, edit files and run commands. This page compares them on where each runs, models, plans and prices, sandboxing, enterprise controls and code review, and says which fits which situation.

OpenAI sells Codex as part of ChatGPT plans. Anthropic sells Claude Code as part of Claude plans. Both count coding work against the plan's usage limits, and both sell more usage beyond those limits.

Prices and other facts are as of November 5, 2026. Vendors change prices; confirm them on the vendor’s own pricing page. Independent analysis: neither project nor any vendor named here paid for or reviewed this page.

The short answer

Choose Codex when

  • you want the CLI's source published under the Apache 2.0 license
  • you want the local agent inside a sandbox from the start, with network access off
  • developers work on Windows without WSL and still need a sandbox

Choose Claude Code when

  • your repositories are on GitHub Enterprise Server
  • cloud sessions must run on compute inside your own network
  • you buy model inference through Google Cloud or Microsoft Azure

Side by side on six points

Compared on OpenAI and Anthropic documentation as of November 2026. Prices are US list prices from each vendor's pricing page as of November 2026.

Where it runs

Codex

A CLI for macOS, Linux and Windows. An IDE extension for VS Code, Cursor and Windsurf. Xcode and JetBrains IDEs offer Codex through their own integrations. The ChatGPT desktop app runs Codex on macOS and Windows, with a Linux install guide. Codex Cloud runs tasks from the web, mobile or the desktop app.

Claude Code

A CLI for macOS, Linux, WSL and Windows. An extension for VS Code and Cursor, and a plugin for JetBrains IDEs that needs the CLI. The Claude desktop app runs on macOS and Windows, and in beta on Ubuntu and Debian. Cloud sessions start from the browser, the Claude mobile app, the desktop app or the terminal.

Both reach the terminal, VS Code, JetBrains IDEs, a desktop app and the cloud.

Models and where inference runs

Codex

OpenAI's GPT models. OpenAI recommends GPT-6 Astra for the most demanding work, GPT-6.1 Sol for near-Astra performance at lower cost, GPT-6.1 Terra for speed and GPT-6 Luna for focused, repeatable tasks. With an API key, models follow the API organization. Local clients can also call OpenAI models on Amazon Bedrock or through a company gateway.

Claude Code

Anthropic's Claude models. On the Anthropic API, the opus, sonnet and haiku aliases resolve to Opus 5.5, Sonnet 5.5 and Haiku 5.5. Fable 5.1 and Fable 5 are never the default and must be selected. The CLI, VS Code and JetBrains can also run through Amazon Bedrock, Claude Platform on AWS, Google Cloud's Agent Platform or Microsoft Foundry.

Each is built around its own vendor's models; Claude Code documents more cloud platforms for inference.

Plans and prices

Codex

Included in ChatGPT plans. Plus is $20 per month. Pro plans are $100, $200 or $500 per month. Business is $20 per user per month billed annually, or $25 billed monthly, for 2 or more users. Enterprise is priced by sales. Free and Go get GPT-6 Luna in the desktop app, subject to rollout. API-key use is billed at API rates and has no cloud features.

Claude Code

Included in Claude plans from Pro up. Free does not include Claude Code. Pro is $20 per month, or $17 per month billed annually. Max is $100 and Ultra $200 per month. Team seats are $20 (Standard) or $100 (Premium) per month billed annually, or $25 and $125 billed monthly, for 2 to 150 people. Enterprise is $20 per seat per month billed annually, with a 20-seat minimum, plus usage at API rates.

Individual and team entry prices match at $20; at enterprise scale, both bill heavy use beyond the seat.

Sandbox and approvals

Codex

An OS-enforced sandbox is on by default in the CLI, IDE extension and desktop app. By default it has no network access and writes only to the active workspace. An approval policy sets when Codex must stop and ask. On Windows, the desktop app has a native sandbox for PowerShell. Each cloud task gets its own isolated workspace.

Claude Code

A permission system asks before shell commands in Manual mode, except a built-in set of read-only commands. An OS-enforced sandbox for shell commands is off by default. It runs on macOS, Linux and WSL2. On native Windows, commands run unsandboxed. File tools, MCP servers and hooks run outside the sandbox. Cloud sessions run in an isolated VM.

Codex starts inside a sandbox; Claude Code starts by asking for approval, and its sandbox has to be turned on.

Enterprise controls and data

Codex

Business adds admin controls, SAML SSO and MFA, with no training on business data by default. Enterprise adds SCIM, EKM, role-based access, audit logs through the Compliance API, and data retention and residency controls. Admins can enforce requirements users can't override, such as sandbox mode, approval policy and allowed MCP servers. With an API key, Codex follows the API organization's retention settings instead.

Claude Code

Team adds SSO, admin tools and server-managed settings, with no model training on content by default. Enterprise adds SCIM, audit logs, a Compliance API, role-based access, custom data retention and IP allowlisting. Commercial data is kept 30 days by default. Zero data retention is available to qualified Enterprise accounts by separate enablement, and it turns off cloud sessions.

Both put SCIM, audit logs and retention controls in the top tier; ask each vendor how retention applies to cloud tasks.

Code review, CI and extensions

Codex

Codex code review posts reviews on GitHub pull requests and is generally available. GitLab merge request review is in preview. The Codex GitHub Action runs Codex in workflows with an OpenAI API key. Cloud environments don't yet support GitLab or self-hosted GitHub Enterprise Server. MCP servers, skills and plugins extend it. SDKs exist for TypeScript and Python.

Claude Code

Code Review, on Team and Enterprise, reviews GitHub pull requests, including GitHub Enterprise Server. It never approves or blocks a pull request. The Claude Code GitHub Action responds to @claude mentions. Review and triage also run in GitLab CI/CD. Cloud sessions clone only from GitHub, and other repositories go up as a bundle. MCP servers, skills and hooks extend it. The Agent SDK supports Python and TypeScript.

Both center on GitHub; Claude Code's review and cloud sessions cover GitHub Enterprise Server, and Codex reviews GitLab merge requests in preview.

Which costs less?

That depends on the model and the work. OpenAI says usage depends on the model, the size of the task and whether it runs locally or in the cloud. Anthropic says there is no fixed message count. As of November 2026, ChatGPT Plus and Claude Pro both list $20 per month. Run a pilot on both and compare usage.

Who makes each

OpenAI makes Codex. The Codex CLI is published on GitHub under the Apache 2.0 license.

Anthropic makes Claude Code. Its GitHub repository states that use is subject to Anthropic's Commercial Terms of Service.

Which fits your situation

Repositories are on GitHub Enterprise Server

Claude Code. Its Code Review and cloud sessions support GitHub Enterprise Server on Team and Enterprise plans. Codex cloud environments don't yet support self-hosted GitHub Enterprise Server.

Code is on GitLab

Codex for pull request review, which covers GitLab merge requests in preview. Claude Code runs in GitLab CI/CD, and its cloud sessions take GitLab code only as an uploaded bundle.

Developers use Windows without WSL

Codex. Its Windows desktop app has a native sandbox for PowerShell. Claude Code runs commands unsandboxed on native Windows.

Cloud tasks must reach services on a private network

Either. Claude Code's self-hosted environments, in public beta on Team and Enterprise, run cloud sessions inside your network. Codex cloud environments can join your network through a Tailscale VPN.

Inference must be bought through Google Cloud or Azure

Claude Code. It runs through Google Cloud's Agent Platform and Microsoft Foundry. The Codex docs cover Amazon Bedrock and company gateways.

Questions buyers ask

Can either run in CI?

Yes. Codex runs in pipelines with codex exec and the Codex GitHub Action. Claude Code runs in CI with claude -p, the Claude Code GitHub Action and GitLab CI/CD.

Do they read the same project instructions file?

Codex reads AGENTS.md. Claude Code reads CLAUDE.md, and can read an existing AGENTS.md in its place.

Is our code used to train models?

Not by default on business plans. OpenAI lists no training on business data by default for ChatGPT Business. Anthropic does not train on code sent to Claude Code under commercial terms unless the customer opts in. On Claude's Free, Pro, Max and Ultra plans, training follows each user's setting.

Sources

Keep reading

Buyer Guide
AI Code Assistants & Coding Agents
Executive Forum
Publish under your own byline

Senior technology leaders write for CIOPages in the Executive Forum.

Job 01
Decide where AI goes in the business

The board wants an AI plan, and every function wants to go first.