LLM Reference
OpenRouter

Claude Sonnet 4 on OpenRouter

Claude 4 · Anthropic

Serverless

Last refreshed 2026-05-25. Next refresh: weekly.

Why use Claude Sonnet 4 on OpenRouter?

OpenRouter offers Claude Sonnet 4 with pay-as-you-go pricing at $3.00/1M input tokens. OpenRouter is a multi-provider LLM aggregator offering unified API access to 300+ models from all major labs and emerging providers, with automatic failover for reliability.

Compare Claude Sonnet 4 across 4 providers to find the best fit for your use case
Input / 1M
$3.00
Output / 1M
$15.00
Cache
Not sourced
Batch
Not sourced

Setup recipe

Docs fallback
Install
Use the provider REST API or SDK
Auth
Create a provider API key
Call
model: anthropic/claude-sonnet-4
Model ID
anthropic/claude-sonnet-4

Request example

Curated snippets for this provider are not sourced yet. Use OpenRouter documentation with model ID anthropic/claude-sonnet-4.

Gotchas

  • Use provider model ID "anthropic/claude-sonnet-4", not the LLMReference slug "claude-sonnet-4".

Compare Claude Sonnet 4 Across Providers

ProviderInput (per 1M)Output (per 1M)
Anthropic$3.00$15.00
AWS Bedrock$8.00$40.00
OpenRouter$3.00$15.00
Vercel AI Gateway$3.00$15.00

Pricing

TypePrice (per 1M)
Input tokens$3.00
Output tokens$15.00

Capabilities

VisionMultimodalStructured Outputs

About Claude Sonnet 4

Claude Sonnet 4 API snapshot (claude-sonnet-4-20250514) is deprecated and scheduled to retire from Anthropic-operated platforms on June 15, 2026. Use Claude Sonnet 4.6 for current integrations.

FAQ

What does Claude Sonnet 4 cost on OpenRouter?

On OpenRouter, Claude Sonnet 4 costs $3 per 1M input tokens and $15 per 1M output tokens.

What is the context window for Claude Sonnet 4 on OpenRouter?

Claude Sonnet 4 supports a 1m token context window on OpenRouter.

How does OpenRouter compare to other Claude Sonnet 4 providers?

Claude Sonnet 4 is available from 4 providers. The cheapest input pricing is $3.00/1M tokens from Anthropic.

What API model ID do I use for Claude Sonnet 4 on OpenRouter?

Use the model ID anthropic/claude-sonnet-4 when calling OpenRouter's API.

Who created Claude Sonnet 4?

Claude Sonnet 4 was created by Anthropic as part of the Claude 4 model family.

Is Claude Sonnet 4 open source?

Claude Sonnet 4 is not open source; the seed data lists it as proprietary.

Get Started