OpenAI has released codex-plugin-cc as open source, an official plugin that allows Codex to run directly from Claude Code. For developers and system administrators, the interesting part is not simply being able to consult a second model: the plugin can review changes, delegate tasks, rescue stalled sessions, transfer entire conversations, and add a review gate that requires Codex approval before Claude can consider a task complete. The official repository already has more than 31,800 GitHub stars and is distributed under the Apache 2.0 license.
The key points about Codex inside Claude Code in 30 seconds
- Installation is handled through Claude Code’s own plugin system and requires Node.js 18.18 or later.
- Codex uses the local CLI, preserving authentication, configuration, and access to the repository.
/codex:reviewreviews changes, while/codex:adversarial-reviewchallenges design decisions./codex:rescuedelegates a problem to Codex, while/codex:transferpreserves context when switching agents.- An optional review gate prevents a task from being completed until it has passed a Codex review.
Getting started does not require manually editing Claude Code configuration files. OpenAI distributes the integration through its own plugin marketplace.
The first step is to add the repository:
/plugin marketplace add openai/codex-plugin-cc
Then install the plugin:
/plugin install codex@openai-codex
Reload the plugins:
/reload-plugins
And finally run:
/codex:setup
This last command checks whether Codex is installed and properly authenticated. If the CLI is missing and npm is available, the setup assistant can offer to install it. It can also be installed manually:
npm install -g @openai/codexCode language: CSS (css)
If Codex is installed but there is no active authenticated session:
codex login
OpenAI requires Node.js 18.18 or later and allows users to work with a compatible ChatGPT subscription, including the free tier according to the current documentation, or with an API key. Usage initiated from Claude Code counts toward the normal Codex usage limits.
A quick test after installation can be performed with:
/codex:review --background
/codex:status
/codex:result
This makes Codex review the current work in the background while Claude Code remains available for other tasks.
Codex Does Not Run “Inside” Claude: It Uses the Local CLI
From a sysadmin perspective, this detail matters.
codex-plugin-cc does not bundle an independent runtime or launch a separate isolated copy of Codex. The plugin acts as an interface to the Codex CLI and Codex app server installed on the same machine.
That means it uses:
- the same authentication;
- the same repository checkout;
- the same local environment;
- the same Codex configuration;
- the same usage limits.
If this file already exists:
~/.codex/config.tomlCode language: JavaScript (javascript)
the plugin uses it.
Project-specific configurations are also supported through:
.codex/config.toml
For example:
model = "gpt-5.4-mini"
model_reasoning_effort = "high"Code language: JavaScript (javascript)
This allows a team to define which model or reasoning level it wants to use from Claude Code without maintaining a separate configuration.
For operations teams, this integration has a clear advantage: it does not introduce another remote platform between the agent and the repository. It relies on the same environment from which Codex would normally run directly.
That does not remove the usual risks. If the agent has access to commands, secrets, private repositories, or deployment tools, the exposure will still depend on how the environment is configured.
/codex:review: A Second Review Without Leaving Claude Code
The most straightforward command is:
/codex:review
It performs a read-only review of the current changes.
It can also compare the active branch against another reference:
/codex:review --base main
OpenAI says it uses the same review quality as running /review directly from Codex. The operation does not modify files.
This can fit particularly well into workflows where Claude Code has written a change and a second assessment is wanted before creating the pull request.
For example:
Claude Code:
- changes the Nginx configuration
- modifies the authentication middleware
- updates the tests
Codex:
- reviews the full diff
- identifies potential problems
- returns observations
The goal should not be to turn Codex into an infallible authority.
The value comes from introducing another reasoning context over the same change. A second model may detect a race condition, regression, or design decision that the first accepted after spending too many turns following the same approach.
For larger changes, it is advisable to run the review in the background:
/codex:review --background
and check it later:
/codex:status
/codex:result
Adversarial Review Is More Interesting Than a Standard Code Review
For critical systems, OpenAI includes another command:
/codex:adversarial-review
Its purpose is not simply to find bugs. It is designed to deliberately challenge the chosen approach.
It can examine areas such as:
- authentication;
- race conditions;
- potential data loss;
- rollback strategies;
- fault tolerance;
- caching decisions;
- retries;
- architectural alternatives.
For example:
/codex:adversarial-review --base main \
challenge whether this retry strategy can duplicate jobsCode language: JavaScript (javascript)
Or:
/codex:adversarial-review --background \
look for race conditions and failure modes
For a system administrator, this mode can be particularly useful for AI-generated infrastructure changes.
One agent may produce a Kubernetes configuration that appears to work. Another can question what happens if a node disappears during deployment, whether the readinessProbe is incorrectly defined, or whether a policy allows more traffic than necessary.
It does not automatically make the configuration secure, but it introduces a deliberate critical-review stage into the workflow.
/codex:rescue: Hand the Problem to Another Agent When Claude Gets Stuck
The plugin also includes:
/codex:rescue
This command delegates a task to a Codex subagent.
For example:
/codex:rescue investigate why the systemd service fails after reboot
Or:
/codex:rescue fix the failing integration test with the smallest safe patchCode language: JavaScript (javascript)
Previous work can also be resumed:
/codex:rescue --resume apply the top fix from the last runCode language: JavaScript (javascript)
and the operation can run in the background:
/codex:rescue --background investigate the regression
This changes how agents can be used.
Until now, it was common to keep Claude Code in one terminal and open Codex in another, manually copying errors, diffs, test output, and explanations between them.
Claude can now delegate a task directly without requiring the user to manually reconstruct the context.
It can even be requested in natural language:
Ask Codex to investigate why this deployment keeps rolling back.Code language: JavaScript (javascript)
The plugin handles the corresponding delegation.
/codex:transfer: Move an Entire Session Without Starting Over
Another common problem appears when an agent has spent half an hour debugging an incident and the developer wants another model to continue the investigation.
Repeating the entire history is inefficient.
That is what this command is designed for:
/codex:transfer
The plugin takes the current Claude Code session, imports it as a persistent Codex session, and returns something similar to:
codex resume <session-id>Code language: HTML, XML (xml)
The work can then continue directly in Codex.
The original session must be located under Claude’s projects directory:
~/.claude/projectsCode language: JavaScript (javascript)
A source can also be specified manually with --source.
The transfer uses Codex’s external-session importer. This does not mean Claude and Codex share the same internal memory: the conversation history is converted and imported so Codex can reconstruct the context and continue from that point.
For long incidents, this could become one of the plugin’s most useful capabilities.
One model can investigate the initial cause of a problem and another can continue from where it stopped without having to ask again:
What have we already tried?
Which logs have we checked?
Which hypotheses have already been ruled out?
A Review Gate Before a Task Can Be Considered Complete
OpenAI includes an even more aggressive optional feature:
/codex:setup --enable-review-gate
When enabled, Claude Code cannot normally finish a task without first running a Codex review.
The workflow becomes roughly:
Claude implements
↓
Codex reviews
↓
Problems found?
↓ ↓
Yes No
↓ ↓
Claude fixes Complete
Technically, this is implemented through a Stop hook.
If Codex finds problems, completion is blocked and Claude can return to the change.
It can be disabled with:
/codex:setup --disable-review-gate
OpenAI warns about an important side effect: this can produce long Claude-Codex loops and quickly consume usage limits. The company recommends keeping the process under active supervision.
For that reason, it will probably make more sense for selected tasks than as a blanket requirement for everything.
A documentation change does not necessarily need the same gate as a Terraform modification, authentication module, or database migration procedure.
An Interesting Workflow for Sysadmins
The plugin makes it possible to build fairly natural workflows for infrastructure management.
For example, Claude could prepare an Ansible modification:
Claude:
modifies the nginx role to enable HTTP/3
Then:
/codex:review --base main
For a more critical assessment:
/codex:adversarial-review \
check rollback, compatibility and failure scenarios
For an incident:
/codex:rescue --background \
investigate why this Kubernetes pod enters CrashLoopBackOffCode language: JavaScript (javascript)
While Codex investigates the problem, Claude can continue reviewing events, manifests, or metrics.
Later:
/codex:status
/codex:result
The pattern starts to look less like “asking an AI a question” and more like distributing an incident between two operators.
Two Agents Still Do Not Replace Tests, CI, or Human Review
There is an obvious temptation with tools like this: assuming that if Claude writes the code and Codex reviews it, the result has automatically been validated.
It has not.
Both models can reproduce the same mistake.
They can also accept the same incorrect assumption, generate dangerous commands, or misinterpret a configuration.
A sensible workflow therefore still looks like this:
Agent → second agent → tests → CI → review → deployment
rather than:
Agent → second agent → production
This is even more important for infrastructure.
A syntactically correct firewall configuration can still expose an unnecessary service. A playbook may work in staging and cause an outage when executed simultaneously across 200 servers. A Terraform change may be valid while still deleting a resource that should never have been touched.
Agents can increase review capacity, but they still need operational safeguards and procedures.
OpenAI Accepts That Codex Does Not Always Have to Be the Primary Agent
Perhaps the most striking aspect is who published the plugin.
The repository sits under OpenAI’s official GitHub organization and its description is explicit: “Use Codex from Claude Code to review code or delegate tasks.”
This is not an unofficial community integration.
OpenAI is making it easier for Codex to operate as a second agent inside the product of one of its main competitors.
The repository was created on March 30, 2026 and, when checked on August 14, had 31,848 stars and 2,187 forks, while being distributed under the Apache 2.0 license.
This could offer a glimpse of where AI-assisted software development is heading.
The question may gradually stop being:
Claude Code or Codex?
and become:
Which agent should implement, which one should review, and which one should investigate when something goes wrong?
For developers and sysadmins, that distinction matters.
The terminal may stop having a single AI copilot and instead become an environment where several agents divide tasks across the same repository.
Frequently Asked Questions
How do you install Codex inside Claude Code?
Add the openai/codex-plugin-cc marketplace, install codex@openai-codex, reload the plugins, and run /codex:setup. Node.js 18.18 or later is also required, and Codex must be installed and authenticated.
What is the difference between /codex:review and /codex:adversarial-review?
/codex:review performs a conventional read-only review. /codex:adversarial-review is designed to challenge decisions, identify hidden assumptions, and examine risks or alternative approaches.
Can Codex modify files from Claude Code?
The standard and adversarial reviews are read-only. /codex:rescue, however, delegates tasks to Codex and can be used to investigate problems or attempt changes depending on the requested task.
Does the plugin require a separate account?
Not necessarily. It uses the local Codex installation and its existing authentication. It can work with a compatible ChatGPT account or an API key, with usage counting toward the normal Codex limits.
