
OpenAI's Official Codex Plugin for Claude Code — Setup and the Strategy Behind Shipping to a Rival
Introduction
In March 2026, OpenAI published openai/codex-plugin-cc on GitHub — an official plugin that lets you call OpenAI's Codex CLI from inside Anthropic's Claude Code. It is the first public case in the AI coding-agent market of one vendor shipping a first-party extension into a direct competitor's CLI.
Once installed, new slash commands appear inside your Claude Code session: /codex:review for a read-only review, /codex:adversarial-review for a steerable review that challenges design decisions, and /codex:rescue for delegating full tasks to Codex in the background. You never have to leave Claude Code to reach for Codex's second opinion.
Key takeaways
- The Codex Plugin for Claude Code is OpenAI's official plugin that exposes
/codex:slash commands inside Claude Code - Install in three steps:
/plugin marketplace add openai/codex-plugin-cc→/plugin install codex@openai-codex→/codex:setup - Use it for standard reviews, adversarial design reviews, and background delegation of long-running tasks
- OpenAI shipped to a rival's CLI to maximize Codex's surface area — a "meet users where they are" move aimed at Claude Code's growing share of the coding-agent market
What is the Codex Plugin for Claude Code?
The Codex Plugin for Claude Code is a first-party plugin that invokes OpenAI's Codex CLI through Claude Code's plugin system. It ships from the openai/codex-plugin-cc repository under OpenAI's GitHub organization.
Crucially, the plugin does not bundle its own Codex runtime. It is a thin wrapper that shells out to the @openai/codex binary and the Codex App Server already installed on your machine, reusing the same ~/.codex authentication. If you are already signed into Codex, there is no separate account to create.
The practical upside of being a wrapper is that everything you have already configured on the Codex side carries over. Custom skills registered under [[skills.config]], subagents defined as [profiles.<name>], custom instructions in ~/.codex/AGENTS.md, and mcp_servers entries in ~/.codex/config.toml all apply when Codex is invoked through the plugin. You get to call your existing Codex setup from inside Claude Code with no rewiring.
The commands you get
| Command | Purpose |
|---|---|
/codex:review | Standard code review of uncommitted changes or a branch diff |
/codex:adversarial-review | Steerable review that challenges design choices and hidden assumptions |
/codex:rescue | Hand a task (bug hunt, fix, investigation) to Codex |
/codex:status / /codex:result / /codex:cancel | Manage background jobs |
/codex:setup | Health-check Codex install, manage the optional review gate |
Every command supports --background, so you can queue a multi-file review or a long-running investigation and keep editing in Claude Code while Codex works.
Why did OpenAI ship a plugin for a competitor's CLI?
OpenAI shipped into Claude Code to expand Codex's surface area into the workflows developers already live in. Fighting Claude Code head-on as a standalone product was leaving reach on the table, and making Codex callable from the competing CLI is cheaper than converting those users.
The numbers explain the move. Anthropic reportedly hit around $30B in annualized revenue in early 2026, with Claude Code alone at an estimated $2.5B ARR and accounting for roughly 4% of all public GitHub commits. Claude Code has become a distribution channel too large for OpenAI to ignore.
Meanwhile, OpenAI is doubling down on Codex. Codex crossed three million weekly users by April 2026 — a 5× jump in three months — and OpenAI launched a new $100/month ChatGPT Pro tier that offers 5× the Codex usage of Plus, explicitly targeting Claude Max subscribers. Shipping a plugin that makes Codex trivially reachable from Claude Code fits the same playbook: put Codex everywhere users already type.
There is also a quiet take-back mechanic. Both /codex:result and /codex:status return a Codex session ID, which means any work started inside Claude Code can be reopened in Codex via codex resume <session-id>. The plugin is both a bridge and a migration path.
How simple is the setup?
Setup is three commands and usually runs in under five minutes. Requirements are Node.js 18.18+ and either a ChatGPT subscription (Free works) or an OpenAI API key.
Step 1: Add the marketplace and install
Run these from the Claude Code prompt in order.
/plugin marketplace add openai/codex-plugin-cc
/plugin install codex@openai-codex
/reload-pluginsStep 2: Verify Codex is ready
/codex:setup/codex:setup checks that the Codex binary is installed and authenticated. If Codex is missing and npm is available, it will offer to install it for you. To install manually:
npm install -g @openai/codex
!codex login # Sign in with ChatGPT or an API keyStep 3: First run
The cleanest first run is a background review.
/codex:review --background
/codex:status
/codex:resultThe /codex:result output includes a Codex session ID so you can reopen the same thread directly in Codex with codex resume <session-id> — useful when you want to continue the investigation inside Codex's own UI.
Enabling /codex:setup --enable-review-gate installs a Stop hook that runs a Codex review every time Claude tries to finish a response, blocking the stop if issues are found. It can create long Claude ↔ Codex loops that burn through usage limits fast. Only turn it on for sessions you actively monitor.
When should you actually use it?
Reach for the plugin when you want a second opinion from a different model family, or when you want to offload heavy work to a fresh context so your main Claude Code session stays clean. That "second brain, new context" pattern is the core value — something a single-agent setup cannot replicate.
Concrete patterns worth stealing:
- Pre-ship review:
/codex:review --base mainover your branch diff to catch things your main agent normalized away - Challenging the design:
/codex:adversarial-review --background challenge the retry and caching designbefore committing to an architecture - Task delegation:
/codex:rescue --background investigate why the flaky integration test started failingwhile you keep editing other files - Cheaper passes:
/codex:rescue --model gpt-5.4-mini --effort medium ...to steer smaller models at specific tasks and conserve usage
The adversarial-review command is the most interesting addition. A normal /codex:review looks for bugs in the code as written; /codex:adversarial-review pressure-tests the decisions behind the code — rollback safety, race conditions, auth edge cases — with optional focus text you can steer toward a specific risk area.
What is the review gate?
The review gate is an optional plugin feature that runs an automatic Codex review whenever Claude Code is about to finish a response, and blocks the stop if Codex flags issues — forcing Claude to address them before completing. Toggle it with /codex:setup --enable-review-gate and /codex:setup --disable-review-gate.
Mechanically, the gate replaces Claude Code's Stop hook (a user-defined script that runs immediately before a response completes). When Claude tries to wrap up, Codex runs a targeted review against Claude's most recent output. If issues are found, the Stop is blocked and Claude is restarted with the directive to fix what Codex flagged before finishing.
The catch: Claude responds → Codex reviews → Claude fixes → Codex reviews again can compound into a Claude ↔ Codex loop that drains both Claude and Codex usage limits in minutes. Long autonomous sessions with the gate enabled can burn through a daily quota in a single sitting.
In practice, treat the review gate as a manual safety valve for high-stakes sessions — turn it on for a critical implementation push, then explicitly run --disable-review-gate when you are done. It is not a "leave it on" feature.
FAQ
Q. Do I need to pay for both Claude Code and Codex?
A. Yes. Codex calls count against your Codex usage limits (ChatGPT subscription or API key), and Claude Code counts against your Anthropic plan. The plugin itself adds no cost.
Q. Does the plugin ship its own Codex runtime?
A. No. It wraps the @openai/codex binary and Codex App Server already installed on your machine, and it picks up your existing ~/.codex/config.toml.
Q. Can I pin the model or reasoning effort for a project?
A. Yes — add a .codex/config.toml at the project root with model = "gpt-5.4-mini" and model_reasoning_effort = "high". Project-level overrides only apply when the project is marked trusted.
Q. Do my Codex-side subagents and custom skills work through the plugin?
A. Yes — all of them. Because the plugin shells out to your local Codex CLI and Codex App Server, the custom skills you registered under [[skills.config]], the subagents defined as [profiles.<name>], the AGENTS.md instructions, and the mcp_servers you configured in ~/.codex/config.toml are all inherited. Whatever you tuned for standalone Codex use is available the moment you call Codex from Claude Code.
Q. Should I enable the review gate?
A. Not as a default. The Stop hook can create long Claude ↔ Codex loops that burn usage. Keep it off unless you are actively watching the session.
Q. Are similar plugins available for Cursor or other IDE agents?
A. There is no official OpenAI plugin for them at the time of writing, but community MCP wrappers such as kky42/codex-as-mcp already expose Codex as an MCP server that any MCP-capable client can call.
Summary
The Codex Plugin for Claude Code is a small technical artifact with an outsized signal: the coding-agent market is shifting from "winner takes the CLI" to an ecosystem where agents call each other and developers assemble second opinions across vendors. OpenAI chose to embed into Claude Code rather than fight it head-on, and the design — right down to returning Codex session IDs — makes it easy to start in Claude Code and migrate work back to Codex later.
For teams standardized on Claude Code, the practical starting move is low-risk: install the plugin, try /codex:review --background on your next branch, and reach for /codex:adversarial-review before shipping anything with non-trivial design decisions. At ZenChAIne we have also covered Codex's multi-agent architecture vs Claude Code and mcp-convert for migrating MCP settings between the two — both useful companions if you are building a cross-agent workflow.