- Step 11 of 12 in the series "Claude Code and Codex, in order"
Codex vs Claude Code vs Cursor: Workflows, Guardrails and Prices

Pick Cursor if you want to watch each edit land in your editor. Pick Codex if you want the agent fenced in safely without setting anything up. Pick Claude Code if you want the most control over how the agent behaves in your repo. All three have a $20 plan, and Cursor also has a free one.
All three can add a form field and a test. That's not where they differ. They differ in where the work happens, what stops the agent from doing something you didn't want, and how you check the result before it merges.
This comparison walks one small task through each tool's documented workflow, then compares features and prices. It's built from vendor documentation and pricing pages read on September 26 and 27, 2026. No tool was run for this page and there are no benchmark numbers. For measured model quality, see the agent benchmarks directory and read how each benchmark was run.
The task
A small Next.js App Router app has a signup form with name and email. The task:
Add a required "company" field to the signup form. Validate it on the server: 2 to 100 characters, trimmed. Show the error under the field. Add a unit test for the validator and update the existing form test. Don't change anything else.
It touches four or five files: the form component, the server action or API route, a validation module, and two test files. It's small enough to review in one sitting, and "done" is easy to check: the tests pass and the changes stay inside those files.
Claude Code on the task
Where it runs. A terminal session in the repo, or the VS Code and JetBrains extensions, the desktop app, or a cloud session. The work happens in your local checkout by default.
Instructions. Claude Code reads CLAUDE.md from the repo root and parent folders at launch. The test command and "don't touch unrelated files" belong there (CLAUDE.md and AGENTS.md guide).
Planning. Plan mode reads the code and proposes changes, but edits nothing until you approve (permission modes). On a five-file change, reading the plan's list of files is the quickest way to catch it reaching too far.
Guardrails. Permission modes decide how much it can do without asking. They run from Manual (it only reads without asking) to acceptEdits to auto, where an automatic checker reviews each action instead of you. Per the docs, auto is the starting mode for interactive terminal and VS Code sessions from v2.1.283.
Deny rules, a list of things it may never do, apply in every mode. A hook is a small script that runs at a set moment. A PreToolUse hook runs before each action and can refuse git commit until lint and tests pass. A hook's deny holds even in bypass mode (hooks for coding agents).
Checking the result. Claude runs the tests in your terminal and you review the changes locally, or it opens a pull request. A second, read-only agent can check the changes against what you asked for (subagents and parallel work).
Codex on the task
Where it runs. The CLI, the IDE extension, the desktop app, or Codex cloud, where the task runs in a cloud environment and comes back as a diff or pull request (Codex cloud docs).
Instructions. Codex reads AGENTS.md from ~/.codex and from each folder between the project root and your working directory, up to 32 KiB by default (Codex AGENTS.md guide).
Guardrails. This is where Codex stands out. It runs inside a sandbox, a fenced-off space with fixed limits. The recommended local setting for a folder under version control pairs a workspace-write sandbox with on-request approvals. Codex can edit and run commands inside your project folder, and has to ask before it edits anything outside it or uses the network. Network access is off by default (Codex approvals and security).
In cloud tasks, internet access is blocked by default while the agent works, though setup scripts can still install dependencies. For this task that helps. The validator and tests need no network, so an agent that can't reach one has fewer ways to surprise you.
Checking the result. Locally, review the changes as with any agent. In the cloud, the result arrives as a diff or pull request, and @codex review asks for a review on GitHub. Codex hooks can block commits too, and Codex asks you to approve a new hook before it runs.
Cursor on the task
Where it runs. Inside the Cursor editor, with the agent in a side pane that searches, edits files, and runs terminal commands (Cursor Agent overview). Cloud agents run the same kind of task on their own branch, in a separate virtual machine in the cloud, launched from the editor, the web, Slack, or an @cursor comment on GitHub (Cursor cloud agents).
Instructions. Project rules live in .cursor/rules. A rule can apply always, to files matching a pattern (called a glob), when the agent decides it's relevant, or when you mention it. Cursor also reads AGENTS.md, including ones in subfolders (Cursor rules docs). A rule for files matching src/lib/validation/** is a natural fit for "validators must have tests".
Guardrails. Cursor asks before running MCP tools by default. It supports hooks in .cursor/hooks.json that can allow, deny or ask on events like beforeShellExecution. And it saves local checkpoints before big changes so you can roll back (Cursor hooks).
Checking the result. This is Cursor's strength for a task this size. The edits land in the editor you're already looking at, right next to the form component. You check each change as it happens instead of reviewing a finished pile of changes later.
That suits work where the code itself is the job. If you mostly need help rewriting documents or answering the odd question, a full coding editor is more than you need.
Capabilities side by side
| Claude Code | Codex | Cursor | |
|---|---|---|---|
| Main surface | Terminal, plus IDE extensions, desktop, cloud | CLI, IDE extension, desktop, cloud | The Cursor editor, plus cloud agents and CLI |
| Instruction file | CLAUDE.md | AGENTS.md | .cursor/rules, AGENTS.md |
| Default local guardrail | Permission modes, with auto mode as the default from v2.1.283 | Sandbox with workspace writes, on-request approvals, network off | Approval for MCP tools, hooks, checkpoints |
| Hooks | Yes, 30+ events, settings.json | Yes, hooks.json or config.toml, trust review | Yes, .cursor/hooks.json |
| Skills | .claude/skills, /name | .agents/skills, $name | .agents/skills or .cursor/skills, / |
| Subagents | Built-in and custom, worktree isolation option | Custom agents in .codex/agents | Subagent hooks documented, and cloud agents run in parallel |
| MCP config | claude mcp add, .mcp.json | codex mcp add, config.toml | .cursor/mcp.json |
| Headless | claude -p | codex exec, read-only by default | agent -p, writes need --force |
| GitHub | claude-code-action, @claude | codex-action, @codex | @cursor on PRs and issues |
Sources: the Claude Code, Codex, and Cursor documentation pages linked above, read September 26, 2026. The advanced pages in this series cover each row in detail: MCP servers, skills, and headless and CI use.
The rows look more alike than different. All three read AGENTS.md or something like it, load skills in the same open format, support MCP, and have hooks. A repo set up well for one is mostly set up for the others, so the choice is less permanent than it looks.
What it costs
Subscription prices as of September 26, 2026. The Claude and ChatGPT rows match the site's coding agent cost calculator data. The Cursor rows are from Cursor's pricing page and plan docs, rechecked September 27, 2026.
| Plan | Monthly price | What it includes for coding |
|---|---|---|
| Claude Pro | $20 ($17 a month billed annually) | Claude Code, sharing the plan's usage limit (Claude pricing) |
| Claude Max 5x | $100 | Claude Code, 5x Pro usage per session (Max plan) |
| Claude Max 20x | $200 | Claude Code, 20x Pro usage per session |
| ChatGPT Plus | $20 | Codex at the plan's usage limit (ChatGPT pricing) |
| ChatGPT Pro 5x | $100 | Codex, 5x Plus usage (Pro tiers) |
| ChatGPT Pro 20x | $200 | Codex, 20x Plus usage. New sign-ups paused since September 10, 2026 |
| Cursor Hobby | $0 | Limited Agent requests and access to Composer, no credit card required (Cursor pricing) |
| Cursor Pro | $20 | Agent with extended limits, frontier models, cloud agents |
| Cursor Pro Plus | $60 | Same plan family as Pro at a higher usage tier. The page doesn't state included amounts (Cursor plan docs) |
| Cursor Ultra | $200 | The top individual tier. Included amounts not stated |
| Cursor Teams | $40 per user | Centralized billing, usage analytics, team-wide privacy mode, SAML/OIDC SSO |
Four notes change the math:
- Usage limits, not features, decide the tier. Each vendor describes the higher tiers as multiples of usage. A small task like this one fits easily on an entry plan. Running several agents at once all day does not.
- Cursor splits included usage into two pools. Per its models and pricing docs, one pool covers Cursor's own models, such as Composer and several Grok models, with more included usage, and the other covers third-party models at each model's API price. When included usage runs out, you add on-demand usage at the same API rates or upgrade. A seat price is not a promise of unlimited frontier-model work.
- Cloud and CI runs can bill differently. Cursor's docs say cloud agents use API pricing for the selected model. Codex runs with an API key bill at API rates. Claude's GitHub action bills at API rates on an API key, or against your subscription with an OAuth token.
- API rates vary by model. As of September 26, 2026, the calculator's data lists Claude Sonnet 5 at $2 per million input tokens and $10 per million output, Claude Opus 5.5 at $4 and $20, and gpt-5.3-codex at $1.75 and $14 (Claude pricing, OpenAI API pricing). Plug your own volume into the calculator rather than trusting a rule of thumb.
What about Windsurf?
Windsurf is now called Devin Desktop. The Devin Desktop page calls it "the new name for Windsurf," built on Windsurf's IDE foundation as a command center for managing several agents. As of September 27, 2026, the same page lists Free, Pro at $20 a month, Max at $200 a month, Teams at $80 a month plus $40 per seat, and custom Enterprise pricing. Its FAQ says existing Windsurf customers keep their current plan and pricing, including legacy Windsurf Enterprise plans, so check your own account terms before assuming the new table applies.
Devin Desktop isn't walked through the task above. If you're weighing it against Cursor, use the questions in the next section: compare how each shows you the plan, what ran, and the final changes.
Before you switch tools
A new tool can look better just because you haven't hit its limits yet. Before moving a real project, name what's wrong with your current setup.
If the agent doesn't understand your project, moving the same vague instructions to a new agent brings the problem with you. If you never said what "done" looks like, the new agent can still stop at something that looks right and isn't. The instruction file and the test command usually matter more than the tool.
Then check the candidate against a small piece of existing work:
| Question | What to inspect |
|---|---|
| Can you understand the proposed change? | The plan, the files it used, and the final diff |
| Can you tell what actually ran? | Commands, checks, failures, and unresolved work |
| Can you separate a completed change from a suggested next step? | Whether the result says what is done and what isn't |
| Can you manage more than one task? | Task isolation, state, and the way back to unfinished work |
| Can you recover from a bad change? | Checkpoints, version history, and the actual rollback steps |
| Can your team use it? | Access, data-processing terms, supported environments, and administration |
This is a checklist, not the result of a test run for this page. If you're building a small internal app and you're not a developer, add one more question: once other people depend on the app, who handles its data access, its updates, and what happens when it breaks?
Which one for which working style
Pick by how you want to check the agent's work, not by a leaderboard.
- Choose Cursor if you want to watch the edit happen. For a task like this one, checking each change in the editor as it lands is the easiest review there is. It suits people who already work in a VS Code-style editor and do most tasks hands-on.
- Choose Codex if you want the safe setup by default. It can only write inside your project, with the network off, locally and in the cloud, without you configuring anything. It suits handing off tasks and reviewing a finished diff or pull request, and teams already paying for ChatGPT.
- Choose Claude Code if you want to shape the agent. Hooks on the most events, permission rules, custom subagents that can each work in their own copy of the repo, and skills that pull in fresh context give the most control over how the agent works. It suits developers who live in the terminal and anyone running the agent from scripts and CI.
If you pay for one and are curious about another, the cheapest test is to run the same small task on the entry plan of each, with the same AGENTS.md. Compare the changes, not the demos. The Claude Code vs GitHub Copilot comparison covers the editor-completion side of the market that this page leaves out.
Previous in the series: Headless and CI use of coding agents.



