LiteLLMLiteLLM/ MODELS

Claude Opus 4.8 vs Claude Opus 5

As of November 10, 2026, Claude Opus 4.8 and Claude Opus 5 cost the same: $5.00 per 1M input tokens and $25.00 per 1M output tokens, and both have a 1M-token context window.

Prices from LiteLLM's price fileChecked

Claude Opus 4.8 vs Claude Opus 5 side by side

Headline prices in US dollars per 1M tokens: each model's own lab where it sells it, otherwise its cheapest provider. Source: LiteLLM model price file, as of November 10, 2026.
Claude Opus 4.8Claude Opus 5
Input, per 1M tokens$5.00$5.00
Output, per 1M tokens$25.00$25.00
Cache read, per 1M tokens$0.50$0.50
Cache write, per 1M tokens$6.25$6.25
Context window1,000,000 tokens1,000,000 tokens
Max output128,000 tokens128,000 tokens
Image inputYesYes
Tool callingYesYes
Structured output (JSON)YesYes
Prompt cachingYesYes
ReasoningYesYes
Providers on LiteLLM810
Price shown is fromAnthropicAnthropic
Added to LiteLLMJune 2026July 24, 2026

Cheapest provider for each

Benchmark scores

From the Epoch AI Benchmarking Hub (CC BY 4.0), data as of August 27, 2026. Some results were run by Epoch and others collected by Epoch from each benchmark's own leaderboard, linked in the first column. Each model's best reported reasoning setting is shown in brackets. Higher is better. Only benchmarks with a score for both models are shown.
BenchmarkClaude Opus 4.8Claude Opus 5
Overall
Epoch Capabilities Index159.9164.5
Coding and agents
FrontierCode46.5%53.4% (max)
APEX-Agents48.9% (max)65.8% (max)
OSWorld 2.020.6% (max)31.4% (max)
Reasoning and knowledge
GPQA Diamond91.0% (max)93.9% (max)
ARC-AGI-272.1% (high)90.4% (max)
SimpleQA Verified53.0% (max)59.9% (max)
Math
FrontierMath (tiers 1-3)80.0% (max)85.6% (max)
FrontierMath (tier 4)56.1% (max)73.2% (max)
OTIS Mock AIME 2024-202598.3% (max)98.9% (max)

Call Claude Opus 4.8 or Claude Opus 5 with LiteLLM

Both use the OpenAI format through LiteLLM, so switching is a model name change. Set each provider's API key in the environment first.

Python SDK
from litellm import completion

messages = [{"role": "user", "content": "Hello!"}]

# Claude Opus 4.8
response = completion(model="claude-opus-4-8", messages=messages)

# Claude Opus 5
response = completion(model="claude-opus-5", messages=messages)

# Claude Opus 4.8, falling back to Claude Opus 5 if the call fails
response = completion(model="claude-opus-4-8", messages=messages, fallbacks=["claude-opus-5"])

FAQ

Which is cheaper, Claude Opus 4.8 or Claude Opus 5?

They cost the same: $5.00 per 1M input tokens and $25.00 per 1M output tokens, as of November 10, 2026.

Which has the larger context window, Claude Opus 4.8 or Claude Opus 5?

Both have a 1,000,000-token context window.

Can I switch from Claude Opus 4.8 to Claude Opus 5 without changing my code?

Yes. Through LiteLLM both use the OpenAI format, so switching means changing the model name from "claude-opus-4-8" to "claude-opus-5", or pointing a LiteLLM gateway model alias at the other model. You can also use one as a fallback for the other.