Skip to content
Rival
How it worksPrivacyTerms
Explore all of Rival

Explore

  • Compare Models
  • All Models
  • Image Comparison
  • Audio Comparison
  • Image Generation
  • Best AI For...
  • Arena
  • API Pricing
  • Challenges

Discover

  • SubjectiveBench
  • Research
  • Research downloads
  • Rival Kits
  • Find your AI taste
  • UI Glow-Up
  • VoiceLock
  • Cost Cutter
  • Agent skills
  • Benchmarks vs Vibes
  • Brief
  • Jailbreak
  • Model Updates
  • Provider Status
  • AI Creators

Connect

  • Methodology
  • Advertise
  • Partnerships
  • Privacy Policy
  • Terms
  • RSS Feed
  1. Home
  2. /
  3. Compare
  4. /
  5. Claude Sonnet 4vsOpenAI Codex Mini
Updated May 2025

Claude Sonnet 4vsOpenAI Codex Mini

Claude Sonnet 4 wins 67% of 21 blind community votes against OpenAI Codex Mini on Rival.

Claude Sonnet 4 and OpenAI Codex Mini compared across 10 shared prompts
SpecClaude Sonnet 4OpenAI Codex Mini
Win rate67%33%
Input price$3/M tokens$1.5/M tokens
Output price$15/M tokens$6/M tokens
Context window200K tokens200K tokens
ParametersNot disclosedNot disclosed
WeightsClosed—
Free API (OpenRouter)NoNo
ReleasedMay 2025May 2025
SWE-bench Verified72.7%71.3%
Side by side

Same prompt, both answers

Opening lines from 2 of the 10 prompts both answered. Formatting stripped, words untouched.

Generate a Stand-Up Routine

Write a 3-minute stand-up comedy routine that isn't based on puns.

Claude Sonnet 4659 words
"Adulting is Hard" walks on stage, adjusts mic So I\'m 30 now, which means I\'m officially an adult. Apparently. Though I still feel like I\'m just a confused teenager wearing a slightly more expensive t-shirt. You know what nobody tells you about being an adult?
Read the full answer
OpenAI Codex Mini595 words
[Comedian walks onstage] Hey, everyone! Great to see you all tonight. I'm Jamie—if you thought that intro was enthusiastic, you should've seen me when I realized this place has Wi-Fi. Seriously, though, I love stand-up.
Read the full answer

Stochastic Consistency Test

Generate 5 jokes. How many are unique?

Claude Sonnet 4100 words
Here are 5 jokes for you: Why don\'t scientists trust atoms? Because they make up everything! I told my wife she was drawing her eyebrows too high. She looked surprised. Why don\'t eggs tell jokes? They\'d crack each other up! I\'m reading a book about anti-gravity. It\'s impossible to put down!
Read the full answer
OpenAI Codex Mini75 words
Sure—here are five jokes: I asked the librarian if books about paranoia were available. She whispered, "They're right behind you." Why did the tomato turn red? Because it saw the salad dressing. I bought a boat because it was for sail. Don't trust stairs—they're always up to something.
Read the full answer
Our Verdict
Claude Sonnet 4
Claude Sonnet 4Winner
OpenAI Codex Mini
OpenAI Codex MiniRunner-up

Pick Claude Sonnet 4. In 21 blind votes, Claude Sonnet 4 wins 67% of the time. That's not luck.

Claude Sonnet 4 takes Image Generation.

Clear winner

Reviewing agent-written code?See a Brief PR report

API pricing

Cost per 1M tokens

Claude Sonnet 4
Input
$3.00
Output
$15.00
OpenAI Codex Mini
Input
$1.50
2.0× cheaper
Output
$6.00
2.5× cheaper

OpenAI Codex Mini is cheaper on both: 2.0× input, 2.5× output.

Where to run it

2 hosts

Claude Sonnet 42 hosts
HostInOutContextUptime
Amazon Bedrock$3.00 in·$15.00 out·200k·100% upGoogle Vertex AI$3.00 in·$15.00 out·1M—
OpenAI Codex Mini

No hosts listed on OpenRouter.

Per million tokens. Prices and uptime via OpenRouter, checked 21 Sep 2026.

Research

What we learned reading every model

FAQ

Common questions

Claude Sonnet 4 is developed by Anthropic while OpenAI Codex Mini is developed by OpenAI. Claude Sonnet 4 has a 200K token context window vs OpenAI Codex Mini's 200K. in 21 community votes on Rival, Claude Sonnet 4 wins 67% of head-to-head matchups. These results are based on blind head-to-head voting across 10 challenges.

Based on 21 community votes on Rival, Claude Sonnet 4 wins 67% of head-to-head matchups against OpenAI Codex Mini. Claude Sonnet 4 is strongest in Image Generation.

Claude Sonnet 4 costs $3/M input tokens and OpenAI Codex Mini costs $1.5/M input tokens. OpenAI Codex Mini is $1.50/M cheaper per input. The more expensive model wins 67% of duels, so the premium may be justified by quality.

Rival presents both models' outputs side-by-side in blind duels. Voters see the responses but don't know which model produced each one, eliminating brand bias. 21 votes have been collected for this pair across 10 challenges. All vote data is part of Rival's open dataset.

Keep exploring

More comparisons

Against the newest arrivals

Claude Sonnet 4 logoGPT-6 Astra Pro logo
Claude Sonnet 4 vs GPT-6 Astra ProLanded Sep 2026
OpenAI Codex Mini logoGPT-6 Astra logo
OpenAI Codex Mini vs GPT-6 AstraLanded Sep 2026
Claude Sonnet 4 logoClaude Fable 5.1 logo
Claude Sonnet 4 vs Claude Fable 5.1Landed Sep 2026
OpenAI Codex Mini logoMuse Spark 1.3 logo
OpenAI Codex Mini vs Muse Spark 1.3Landed Sep 2026
Claude Sonnet 4 logoHy4 Preview logo
Claude Sonnet 4 vs Hy4 PreviewLanded Sep 2026
OpenAI Codex Mini logoGemini 3.8 Flash logo
OpenAI Codex Mini vs Gemini 3.8 FlashLanded Sep 2026
Claude Sonnet 4 logoMuse Spark 1.3 Contributor logo
Claude Sonnet 4 vs Muse Spark 1.3 ContributorLanded Sep 2026
OpenAI Codex Mini logoMercury 2.5 Preview logo
OpenAI Codex Mini vs Mercury 2.5 PreviewLanded Sep 2026

Same lab, same size, long tail

Claude Sonnet 4 logoClaude Opus 4 logo
Claude Sonnet 4 vs Claude Opus 4Version compare
Claude Sonnet 4 logoClaude Opus 4.6 logo
Claude Sonnet 4 vs Claude Opus 4.6Version compare
OpenAI Codex Mini logoGPT-6 Astra Pro logo
OpenAI Codex Mini vs GPT-6 Astra ProSame lab
OpenAI Codex Mini logoGPT-5.6 Luna logo
OpenAI Codex Mini vs GPT-5.6 LunaSame lab
Claude Sonnet 4 logoMistral Large 2 logo
Claude Sonnet 4 vs Mistral Large 2Same size
Claude Sonnet 4 logoMistral Large 3 2512 logo
Claude Sonnet 4 vs Mistral Large 3 2512New provider
Claude Sonnet 4 logoMistral Medium 3 logo
Claude Sonnet 4 vs Mistral Medium 3Same size
OpenAI Codex Mini logoMistral Small 4 logo
OpenAI Codex Mini vs Mistral Small 4New provider

Model pages

Claude Sonnet 4 logo
Claude Sonnet 459 outputs, specs and price
OpenAI Codex Mini logo
OpenAI Codex Mini10 outputs, specs and price
Rival
How it worksPrivacyTerms
Explore all of Rival

Explore

  • Compare Models
  • All Models
  • Image Comparison
  • Audio Comparison
  • Image Generation
  • Best AI For...
  • Arena
  • API Pricing
  • Challenges

Discover

  • SubjectiveBench
  • Research
  • Research downloads
  • Rival Kits
  • Find your AI taste
  • UI Glow-Up
  • VoiceLock
  • Cost Cutter
  • Agent skills
  • Benchmarks vs Vibes
  • Brief
  • Jailbreak
  • Model Updates
  • Provider Status
  • AI Creators

Connect

  • Methodology
  • Advertise
  • Partnerships
  • Privacy Policy
  • Terms
  • RSS Feed