Practical agent comparison

Codex vs Claude Code

Both products document repository guidance, coding tools, file modification, shell execution, and approval boundaries. Codex prompt claims are scoped mainly to Codex CLI with GPT-5.2. Claude Code documentation covers CLI and IDE-oriented surfaces without fixing one model, and it documents repository auto memory. Comparable Codex memory is not established. Before moving automation, recheck context, memory, and permission assumptions.

Reviewed
Products
OpenAI Codex · Claude Code
Decision criteria
9 reviewed questions

Comparison orientation

Four reviewed dimensions at a glance

Each dimension links to its detailed evidence row. State labels describe the selected evidence.

Who this comparison is for

How do the documented instruction systems of Codex and Claude Code differ?

Developers and platform teams transferring repository-based coding workflows between Codex CLI and Claude Code.

Evidence-bounded scope

Product, surface, and model context

These summaries combine only the scope stated in the reviewed answers. Each criterion keeps its narrower limits.

OpenAI Codex

Surfaces represented
Codex CLI
Model context represented
GPT-5.2

Claude Code

Surfaces represented
Claude Code terminal CLI · Claude Code IDE integrations
Model context represented
Not established

Practical behavior comparison

What the selected evidence establishes

“Not established” records an evidence gap. It does not mean the product lacks the capability.

Behavior Intelligence comparison of OpenAI Codex and Claude Code
CriterionOpenAI CodexClaude CodeInterpretation
Repository / project instructions Repository guidance must be placed in the target agent's documented instruction hierarchy. Documented

AGENTS.md repository guidance

Surface
Codex CLI
Model
Not established
Config/version
Instruction discovery follows the documented repository path and size limits.
Documented

Scoped CLAUDE.md hierarchy

Surface
Claude Code terminal CLI · Claude Code IDE integrations
Model
Not established
Config/version
Not established
Read practical implication
Memory / persistent context Durable workflow context should not be assumed to persist across agent environments. Not established

Persistent memory not established

Surface
Not established
Model
Not established
Config/version
Not established
Review the documented evidence gap
Documented

Repository-scoped auto memory

Surface
Claude Code terminal CLI · Claude Code IDE integrations
Model
Not established
Config/version
Not established
Read practical implication
Planning / work decomposition Planning assumptions shape how teams structure, review, and resume multi-step work. Documented

Making and updating plans

Surface
Codex CLI
Model
GPT-5.2
Config/version
Not established
Documented

Plan mode before source edits

Surface
Claude Code terminal CLI
Model
Not established
Config/version
Current product documentation consulted 2026-09-14; enabled mode, settings, and deployment still determine availability.
Read practical implication
Tools / tool calling A portable workflow must use only the tools established by the selected evidence. Documented

Terminal and patch function calls

Surface
Codex CLI
Model
GPT-5.2
Config/version
Actual tool availability and escalation depend on the specific run configuration.
Documented

Read, edit, execute, and external tools

Surface
Claude Code terminal CLI · Claude Code IDE integrations
Model
Not established
Config/version
Permission rules and modes can constrain tool execution.
Read practical implication
Filesystem / file modification Repository reads and mutations require the correct workspace and review boundary. Documented

Workspace files and patch calls

Surface
Codex CLI
Model
GPT-5.2
Config/version
Workspace access and patch approval depend on the run configuration.
Documented

Reads and edits codebase files

Surface
Claude Code terminal CLI · Claude Code IDE integrations
Model
Not established
Config/version
Permission rules distinguish read-only and mutating actions.
Read practical implication
Shell / terminal execution Command-heavy automation depends on the target harness's execution controls. Documented

Terminal command function calls

Surface
Codex CLI
Model
GPT-5.2
Config/version
Commands may require user approval depending on the run configuration.
Documented

Runs commands through codebase tools

Surface
Claude Code terminal CLI
Model
Not established
Config/version
Permission rules and modes determine when command execution is allowed or asks for approval.
Read practical implication
Browsing / network access Current external information cannot be assumed available when browsing scope is unestablished. Documented

Cached or live CLI web search

Surface
Codex CLI
Model
Not established
Config/version
Current product documentation consulted 2026-09-14; enabled mode, settings, and deployment still determine availability.
Documented

WebSearch and WebFetch

Surface
Claude Code terminal CLI
Model
Not established
Config/version
Current product documentation consulted 2026-09-14; enabled mode, settings, and deployment still determine availability.
Read practical implication
Approvals / permissions Consent, confirmation, and isolation rules determine which delegated actions can proceed. Documented

Configuration-dependent approval escalation

Surface
Codex CLI
Model
GPT-5.2
Config/version
The specific run determines which calls require escalation.
Documented

Deny, ask, allow, and permission modes

Surface
Claude Code terminal CLI · Claude Code IDE integrations
Model
Not established
Config/version
Rules can be managed at different settings scopes and by the client environment.
Read practical implication
Context scope / inheritance Instructions and tools remain dependable only when their surface, model, and configuration boundaries are preserved. Documented

Harness, workspace, and repository context

Surface
Codex CLI
Model
Not established
Config/version
The current instruction-discovery claim covers Codex CLI; the historical harness excerpt remains scoped to GPT-5.2.
Documented

Managed, user, project, local, and memory scopes

Surface
Claude Code terminal CLI · Claude Code IDE integrations
Model
Not established
Config/version
The reviewed evidence covers terminal and IDE-oriented product surfaces with a selectable Claude model.
Read practical implication

Criterion-by-criterion interpretation

Scope, limitations, and evidence

Behavior Intelligence supplies the factual answers. Editorial implications remain separate.

01

How do AI agents use repository or project instructions?

Open evidence across six products

Why it matters. Repository guidance must be placed in the target agent's documented instruction hierarchy.

OpenAI Codex

Documented
Direct factual answer

Codex supports repository-scoped guidance through AGENTS.md and AGENTS.override.md in the documented context assembly. Codex home guidance loads before project guidance; project discovery selects at most one file per directory from the project root to the working directory.

Surface
Codex CLI
Model context
Not established
Configuration / version
Instruction discovery follows the documented repository path and size limits.
Limits and uncertainty
  • The selected evidence does not establish every runtime instruction input.

Claude Code

Documented
Direct factual answer

Claude Code documents managed, user, project, and local CLAUDE.md instruction scopes for coding-agent work.

Surface
Claude Code terminal CLI · Claude Code IDE integrations
Model context
Not established
Configuration / version
Not established
Limits and uncertainty
  • The complete default base system prompt is not established.
02

Does the product document memory or persistent context?

Open evidence across six products

Why it matters. Durable workflow context should not be assumed to persist across agent environments.

OpenAI Codex

Not established
Direct factual answer

The limited Codex excerpt and repository-guidance source do not establish a separate persistent memory mechanism.

Surface
Not established
Model context
Not established
Configuration / version
Not established
Limits and uncertainty
  • Workspace context and AGENTS.md instructions are not treated as memory.

No source link is attached because the reviewed evidence does not establish this answer.

Claude Code

Documented
Direct factual answer

Claude Code documents repository-scoped auto memory that stores selected learnings separately from human-authored CLAUDE.md instructions.

Surface
Claude Code terminal CLI · Claude Code IDE integrations
Model context
Not established
Configuration / version
Not established
Limits and uncertainty
  • Auto memory is context, not hard policy enforcement.
03

How is planning or work decomposition documented?

Open evidence across six products

Why it matters. Planning assumptions shape how teams structure, review, and resume multi-step work.

OpenAI Codex

Documented
Direct factual answer

The selected Codex prompt excerpt explicitly names making and updating plans as part of the assistant's working interface.

Surface
Codex CLI
Model context
GPT-5.2
Configuration / version
Not established
Limits and uncertainty
  • The excerpt does not prescribe one universal decomposition procedure.

Claude Code

Documented
Direct factual answer

Plan mode researches and proposes changes before source edits. It can run exploratory shell commands and write a plan. Outside sessions with bypass permissions available, source edits remain blocked until plan approval. Command review depends on mode, settings, and version; approval exits planning into the selected execution mode. CLI evidence is not a universal read-only sandbox claim.

Surface
Claude Code terminal CLI
Model context
Not established
Configuration / version
Current product documentation consulted 2026-09-14; enabled mode, settings, and deployment still determine availability.
Limits and uncertainty
  • This claim does not update the dated prompt snapshot or establish every runtime configuration.
04

What tools or tool-calling capabilities are documented?

Open evidence across six products

Why it matters. A portable workflow must use only the tools established by the selected evidence.

OpenAI Codex

Documented
Direct factual answer

Codex's selected prompt excerpt names function calls for terminal commands and patch application.

Surface
Codex CLI
Model context
GPT-5.2
Configuration / version
Actual tool availability and escalation depend on the specific run configuration.
Limits and uncertainty
  • The excerpt is not a complete tool inventory.

Claude Code

Documented
Direct factual answer

Claude Code documents tools for reading code, editing files, running commands, and connecting to external tools.

Surface
Claude Code terminal CLI · Claude Code IDE integrations
Model context
Not established
Configuration / version
Permission rules and modes can constrain tool execution.
Limits and uncertainty
  • The selected evidence does not establish that every deployment exposes every external tool.
05

Can the agent read or modify files?

Open evidence across six products

Why it matters. Repository reads and mutations require the correct workspace and review boundary.

OpenAI Codex

Documented
Direct factual answer

Codex's selected excerpt says the harness can supply workspace files and that the assistant can emit patch function calls.

Surface
Codex CLI
Model context
GPT-5.2
Configuration / version
Workspace access and patch approval depend on the run configuration.
Limits and uncertainty
  • The selected excerpt does not establish unrestricted filesystem access.

Claude Code

Documented
Direct factual answer

Claude Code's official overview says the product reads code, edits files, and runs commands.

Surface
Claude Code terminal CLI · Claude Code IDE integrations
Model context
Not established
Configuration / version
Permission rules distinguish read-only and mutating actions.
Limits and uncertainty
  • Access remains bounded by the client environment and configured permissions.
06

Can the agent execute shell or terminal commands?

Open evidence across six products

Why it matters. Command-heavy automation depends on the target harness's execution controls.

OpenAI Codex

Documented
Direct factual answer

Codex's selected excerpt explicitly names function calls that run terminal commands.

Surface
Codex CLI
Model context
GPT-5.2
Configuration / version
Commands may require user approval depending on the run configuration.
Limits and uncertainty
  • The selected excerpt does not establish unrestricted command execution.

Claude Code

Documented
Direct factual answer

Claude Code's official overview documents command execution as part of codebase operations.

Surface
Claude Code terminal CLI
Model context
Not established
Configuration / version
Permission rules and modes determine when command execution is allowed or asks for approval.
Limits and uncertainty
  • The exact command environment is deployment-specific.
07

Can the product browse or access web and network resources?

Open evidence across six products

Why it matters. Current external information cannot be assumed available when browsing scope is unestablished.

OpenAI Codex

Documented
Direct factual answer

Interactive Codex CLI defaults to cached web search; --search selects live web search. This tool capability does not establish unrestricted shell network access or every session configuration.

Surface
Codex CLI
Model context
Not established
Configuration / version
Current product documentation consulted 2026-09-14; enabled mode, settings, and deployment still determine availability.
Limits and uncertainty
  • This claim does not update the dated prompt snapshot or establish every runtime configuration.

Claude Code

Documented
Direct factual answer

WebSearch returns search titles and URLs; WebFetch retrieves and processes a page, with lossy summarization and possible truncation. Tool/domain rules and provider support apply. Amazon Bedrock does not expose the server-side search tool; an Azure-hosted Foundry deployment does not support it. Web tools do not establish arbitrary network access.

Surface
Claude Code terminal CLI
Model context
Not established
Configuration / version
Current product documentation consulted 2026-09-14; enabled mode, settings, and deployment still determine availability.
Limits and uncertainty
  • This claim does not update the dated prompt snapshot or establish every runtime configuration.
08

What approval or permission controls are documented?

Open evidence across six products

Why it matters. Consent, confirmation, and isolation rules determine which delegated actions can proceed.

OpenAI Codex

Documented
Direct factual answer

Codex's selected excerpt says terminal and patch calls may be escalated to the user for approval depending on configuration.

Surface
Codex CLI
Model context
GPT-5.2
Configuration / version
The specific run determines which calls require escalation.
Limits and uncertainty
  • The excerpt does not define every sandbox or approval mode.

Claude Code

Documented
Direct factual answer

Claude Code documents deny, ask, and allow rules with precedence, plus permission modes that constrain tool execution.

Surface
Claude Code terminal CLI · Claude Code IDE integrations
Model context
Not established
Configuration / version
Rules can be managed at different settings scopes and by the client environment.
Limits and uncertainty
  • The selected evidence does not establish every deployment policy.
09

How is context scoped or inherited across products and agents?

Open evidence across six products

Why it matters. Instructions and tools remain dependable only when their surface, model, and configuration boundaries are preserved.

OpenAI Codex

Documented
Direct factual answer

Codex's selected sources establish harness-supplied workspace context and authored guidance from Codex home followed by project instruction files. Current discovery documentation is separate from the pinned GPT-5.2 prompt excerpt.

Surface
Codex CLI
Model context
Not established
Configuration / version
The current instruction-discovery claim covers Codex CLI; the historical harness excerpt remains scoped to GPT-5.2.
Limits and uncertainty
  • The complete runtime context assembly is not established.

Claude Code

Documented
Direct factual answer

Claude Code documents managed, user, project, and local CLAUDE.md scopes plus separate repository-scoped auto memory.

Surface
Claude Code terminal CLI · Claude Code IDE integrations
Model context
Not established
Configuration / version
The reviewed evidence covers terminal and IDE-oriented product surfaces with a selectable Claude model.
Limits and uncertainty
  • The complete default system prompt is not established.

Workflow guidance

Migration considerations

These implications follow from the reviewed criteria. They do not express a product preference.

Example: move a payment-service review from Codex to Claude Code

Keep the same review contract while separating team instructions, personal preferences, and the permission to edit.

  1. Start with three explicit requirements: the repository requires its payment tests, your personal preference is concise findings, and this task permits review only. These are example requirements, not product defaults.
  2. Keep the test requirement in repository AGENTS.md for Codex and project CLAUDE.md for Claude Code. Move the personal preference from Codex home AGENTS.md to Claude Code user-scope CLAUDE.md; do not commit personal guidance into the project merely to make it visible.
  3. Before starting Codex from a nested payment directory, check AGENTS.override.md along its root-to-working-directory chain. It can replace AGENTS.md at that level. Inspect Claude Code managed, user, project, and local context separately; renaming files does not transfer precedence.
  4. Request the same artifact: affected call paths, findings with file evidence, and proposed tests. Claude Code Plan mode can support analysis before source edits, but shell behavior and bypass availability still matter. The Codex pinned planning excerpt does not establish an identical permission mode.
  5. Handoff condition: the destination can identify the applicable team rule and produce the review artifact with the intended tool permissions. Carry unresolved findings in the task; do not assume Claude Code auto memory becomes Codex memory, or that an instruction file enforces a tool prohibition.

Keep plans and durable context explicit

A documented Codex planning interface and Claude Code auto memory do not create equivalent behavior across both products; state required artifacts and persistence needs.

Check external-information requirements

For a documentation lookup, require a source URL and the relevant page evidence. Check whether Codex search is live or cached; on Claude Code verify search-provider support and permission to fetch the destination domain.

Comparison-specific evidence

Differences in available evidence

Available first-party evidence covers different parts of the Codex and Claude Code instruction systems. Those evidence differences do not establish a product preference. The analysis below adds prompt and product context to the shared behavior criteria.

  1. 01

    Available prompt evidence differs

    Codex has a limited first-party prompt excerpt. The selected Claude Code sources establish an instruction architecture but not a complete default prompt.

  2. 02

    Both document repository guidance

    Codex documents repository/project guidance through AGENTS.md, while Claude Code documents scoped CLAUDE.md instructions and a separate repository auto-memory mechanism.

  3. 03

    Both separate tools from approval controls

    Both products document tool use and harness-level control boundaries, but the selected sources expose different levels of permission detail.

Source-specific detail

Product and prompt evidence

These criteria cover prompt visibility, product identity, and other evidence specific to this comparison.

OpenAI Codex and Claude Code source-specific evidence comparison
CriterionOpenAI CodexClaude Code
Product and model roleEditorial interpretation. Both products are coding agents whose active model remains separate from the product itself. documented

Codex CLI is the product surface; GPT-5.2 is the model named in the selected pinned prompt, not every Codex runtime.

documented

Claude Code is a multi-surface coding product with separately selectable Claude model context.

Base-prompt visibilityEditorial interpretation. Evidence availability differs; absence from the selected source set is not proof that a product lacks internal base instructions. documented

Promptcred maps a limited prompt excerpt published in OpenAI's first-party repository, with completeness and rights limits attached.

not established

The selected official Claude Code documentation does not establish a complete default system prompt; its public reader is architecture analysis.

Project instructionsEditorial interpretation. Both products document repository guidance, but Codex assembles AGENTS.md files along the project path while Claude Code documents managed, user, project, and local CLAUDE.md scopes. documented

Codex documents repository and project guidance through AGENTS.md and AGENTS.override.md files aggregated from the Git/project root to the working directory.

documented

Managed, user, project, and local CLAUDE.md scopes are documented as instruction inputs.

ToolsEditorial interpretation. Both products expose agentic operations, but the sources describe them at different levels of detail. documented

The Codex excerpt names terminal-command and patch calls and says availability depends on configuration.

documented

Claude Code documentation describes reading code, editing files, running commands, and connecting to external tools.

Permission controlsEditorial interpretation. Both products enforce some tool permissions through the product harness, outside the prompt text. documented

The prompt excerpt makes approval escalation configuration-dependent but does not provide a complete permission-rule taxonomy.

documented

Claude Code documents deny, ask, and allow rule evaluation plus permission modes.

Persistent memoryEditorial interpretation. Only Claude Code's selected source set supports a repository-scoped memory claim. not established

The limited Codex excerpt does not establish a persistent memory mechanism.

documented

Claude Code documents auto memory as a repository-scoped store separate from human-authored CLAUDE.md files.

Using the evidence

How to read this evidence

Match prompt claims to the available evidence

Codex supports limited excerpt-level statements. Claude Code supports architecture claims, not a full-prompt transcription.

Inspect the context layer you depend on

Both products document repository guidance: Codex through AGENTS.md and Claude Code through scoped CLAUDE.md files. Claude Code's selected sources also establish a separate auto-memory mechanism.

Primary-source trail

Sources used in this comparison

Each source links to its product evidence, with provenance and publication limits preserved.

OpenAI Codex

Claude Code

Read the comparison and publication methodology

Deeper cross-agent context

Open the six-product answer for broader evidence and scope.

Continue comparing

Available pages

Search Promptcred

Type to search available pages.