---
title: "How to use Claude Code and Codex together: one writes, one reviews"
description: "Claude Code and Codex together work best as writer and reviewer, and OpenAI's codex-plugin-cc runs a read-only Codex review from inside a Claude Code session."
url: "https://aldena.ai/blog/claude-code-and-codex-together"
---

# How to use Claude Code and Codex together: one writes, one reviews

Published 2026-11-15.

Claude Code and Codex together work best as a writer and a reviewer, and OpenAI's [Codex plugin for Claude Code](https://github.com/openai/codex-plugin-cc) runs that review without leaving the Claude Code session. I checked every command here against the plugin's README and both tools' docs on November 15, 2026.

## Four ways to run Claude Code and Codex together

Claude Code and Codex run together in four setups: OpenAI's plugin inside Claude Code, two terminals on one checkout, one git worktree per tool, and GitHub's coding agents.

| Setup                  | Who drives  | How work moves between the tools                  | Where it runs |
| ---------------------- | ----------- | ------------------------------------------------- | ------------- |
| OpenAI's Codex plugin  | Claude Code | Slash commands at the Claude Code prompt          | Your machine  |
| Two terminals          | You         | You paste findings from one window into the other | Your machine  |
| One worktree per tool  | You         | Each tool commits to its own branch               | Your machine  |
| GitHub's coding agents | GitHub      | Each agent opens its own draft pull request       | GitHub        |

The plugin is the one I use, because it is the only setup of the four where one tool checks the other and I paste nothing. Inside Claude Code, `/plugin marketplace add openai/codex-plugin-cc`, `/plugin install codex@openai-codex`, `/reload-plugins` and `/codex:setup` install it and check that Codex is signed in. It drives the global `codex` binary with your existing Codex login, and `/codex:transfer` turns the current session into a Codex thread you pick up with `codex resume`.

Two terminals on one checkout is the weakest setup, since both tools edit the same files and I become the message bus between them. A [worktree per tool](https://aldena.ai/blog/run-multiple-claude-code-agents) stops the collisions but not the pasting. GitHub has let you assign one issue to Claude, Codex, Copilot or all three since its [February 4 changelog](https://github.blog/changelog/2026-02-04-claude-and-codex-are-now-available-in-public-preview-on-github/), on Copilot Business and Pro since [February 26](https://github.blog/changelog/2026-02-26-claude-and-codex-now-available-for-copilot-business-pro-users/). That buys parallel attempts at the issue, and I still compare the drafts myself.

## Split Claude Code and Codex by role, not by stack

Claude Code and Codex split best by role, and the shakacode team's [guide to using both](https://github.com/shakacode/claude-code-commands-skills-agents/blob/main/docs/claude-code-with-codex.md) lists "Implement with Claude, Review with Codex" as its first workflow.

![The writer and reviewer loop: a person describes the task, Claude Code writes, Codex runs /codex:review and edits nothing, Claude Code fixes the findings, and a person merges, with an optional review gate](https://cdn.aldena.ai/images/blog/claude-code-and-codex-together-1-20261115.png)

The same guide says "Both tools are highly capable across all tasks" and leaves the choice to whichever one you know better. I agree with it. A rule like "Claude Code for the frontend, Codex for the tests" reads like one person's habit, and I have never seen one come with evidence.

The role split works for a duller reason. A reviewer that didn't write the code reads the diff cold. It never saw the shortcut the writer took an hour ago, so it judges what is on the page, and a second model brings different blind spots.

Inside Claude Code, `/codex:review --base main` runs a standard Codex review of the branch against `main`. It is read-only and takes no instructions. `/codex:adversarial-review` is the steerable version. It also edits nothing, accepts focus text after its flags and questions design choices, so I point it at the part I trust least ("the retry logic in the webhook handler"). Of the [review tools built for agent-written pull requests](https://aldena.ai/blog/ai-code-review-tools), this is the simplest to try, since it reuses the Codex login you already have.

The plugin can make the review automatic. `/codex:setup --enable-review-gate` adds a `Stop` hook, so Codex reviews each Claude Code response and blocks the stop when it finds issues. The README is blunt about the cost: "The review gate can create a long-running Claude/Codex loop and may drain usage limits quickly." I leave the gate off and turn it on for one risky change at a time, such as a migration or anything near auth.

The roles flip easily. When Claude Code is stuck on a bug, `/codex:rescue` hands the task to Codex through a subagent, and Claude Code reviews the fix.

## Give both tools one instruction file

Codex reads AGENTS.md, and since version 2.1.277 [Claude Code reads AGENTS.md too](https://code.claude.com/docs/en/memory) when the repository has no CLAUDE.md, so one file carries the rules for both tools.

Two instruction files drift. Fix a test command in CLAUDE.md, forget AGENTS.md, and the reviewer judges good code against stale rules.

A `CLAUDE.md`, `.claude/CLAUDE.md` or `CLAUDE.local.md` in the working directory or any directory above it stops Claude Code from reading AGENTS.md directly. The last of those catches teams. A teammate who adds a `CLAUDE.local.md` for personal notes stops getting AGENTS.md in their own sessions, and I'd check for that first when one person's agent ignores [the house rules](https://aldena.ai/blog/share-claude-code-rules-across-a-team).

![One AGENTS.md at the repository root, read by Codex from the root down to the working directory up to 32 KiB, and by Claude Code either directly when no CLAUDE.md exists or through an @AGENTS.md import on the first line of CLAUDE.md](https://cdn.aldena.ai/images/blog/claude-code-and-codex-together-2-20261115.png)

So I keep the rules in AGENTS.md and make CLAUDE.md a pointer. Its first line is `@AGENTS.md`, an import Claude Code reads before the rest of the file, and only Claude-specific notes go below it. Anthropic's docs say the import never makes Claude Code read AGENTS.md twice.

Codex walks from the project root down to the working directory, joins every AGENTS.md it finds and stops at 32 KiB by default (`project_doc_max_bytes`), per [OpenAI's AGENTS.md guide](https://learn.chatgpt.com/docs/agent-configuration/agents-md). It ignores CLAUDE.md unless you add it to `project_doc_fallback_filenames`, which is one more reason the rules live in AGENTS.md.

## Each tool bills a different account

Claude Code runs on a Claude plan or an Anthropic API key, Codex on a ChatGPT plan or an OpenAI API key, so two tools mean two usage limits.

[Claude Code's authentication docs](https://code.claude.com/docs/en/authentication) list Pro, Max and Ultra subscriptions, Teams and Enterprise seats, Claude Console logins, and Amazon Bedrock, Google Cloud's Agent Platform and Microsoft Foundry. The plugin's README asks for a "ChatGPT subscription (incl. Free) or OpenAI API key", and plugin reviews count against your Codex limits.

For one developer that is two bills. A team gets two harder questions. Whose plan does the reviewer run on when it reviews a colleague's branch? Where do both tools' permission prompts go when nobody watches that terminal? I worked through them for Claude Code alone in [Claude Code for teams](https://aldena.ai/blog/claude-code-for-teams), and adding Codex means answering each one twice.

## How Claude Code and Codex work together in Aldena

Aldena runs Claude Code and Codex as agent runtimes inside the conversation's sandbox, so a build agent on Claude Code and a review agent on Codex work in one project.

Aldena is my product, so read this section as the pitch it is.

![Aldena's new shared agent form for an agent named Diff Reviewer, with the runtime list open: Anthropic, OpenAI and OpenRouter API keys, then Claude Code and Codex highlighted](https://cdn.aldena.ai/images/blog/claude-code-and-codex-together-3-20261115.png)

Hiring an [agent](https://aldena.ai/features/agents) sets its runtime, model and effort, and each can change later in the agent's detail. The writer and reviewer split becomes two hires. The Full-Stack Build agent runs on Claude Code, on each member's own Claude plan or on the team's Anthropic key for anyone who hasn't signed in. The reviewer, the built-in Code Review agent or a custom one like the Diff Reviewer above, runs on Codex with the team's OpenAI key, which the provider bills directly with nothing added by Aldena. ChatGPT plans are not supported yet, so Codex needs that key.

On the [org chart](https://aldena.ai/features/org-chart), the Delivery agent delegates the build, drives the review loop, commits and opens the pull request, and never writes code itself. It works strictly one delegate at a time, so two agents never edit the same checkout at once. The Code Review agent reviews the diff across five lenses, reports findings and never edits code. No agent merges its own work, so a person merges what the Delivery agent opens ([human in the loop](https://aldena.ai/features/human-in-the-loop)).

For a team, I'd argue the inbox matters more than either runtime. When either agent waits on a person, its project chat lands in the team inbox, grouped by project and oldest first, and any member can answer. I want CLI versions pinned too, and each project stays on its Claude Code and Codex versions until an owner or admin updates it in the Runtimes settings. A project imports the skills, agents and commands already in a repository's `.agents`, `.claude` and `.cursor` folders.

I still run the plugin for solo work on my laptop. Aldena is for when the agents should run in a sandbox on the team's own account ([isolated projects](https://aldena.ai/features/isolated-projects)), on members' Claude plans and the team's keys, with one inbox for both tools' questions.

## Start with the plugin and one AGENTS.md

OpenAI's Codex plugin and one shared AGENTS.md are the whole setup for one developer, and four commands inside Claude Code install the plugin from its README.

Move the rules into AGENTS.md and put `@AGENTS.md` at the top of CLAUDE.md. Install the plugin. On your next branch, run `/codex:review --base main` before you open the pull request, and read Codex's findings before Claude Code's summary. If the findings are still noise after a week, swap the roles and let Codex write.
