All insights

Coding agents

Claude Code Opus 4: Availability, Coding Fit, and API Migration

Anthropic scheduled Claude Opus 4’s API retirement for June 15, 2026, a date that has passed. Here’s what is verified about Claude Code access, Opus 4’s historical coding results, and using a currently documented API model.

Illustration for Claude code opus 4

Short answer: Claude Opus 4 was Anthropic’s 2025 coding model. Anthropic’s release notes scheduled its API retirement for June 15, 2026, a date that has passed. The current deprecation documentation explains that requests to retired models fail and that its dates apply to Anthropic-operated platforms. However, the official page text available for this update did not expose Opus 4’s specific status entry, so I can’t confirm from that entry that requests to Opus 4 currently fail. Treat Opus 4 as a model to migrate away from—not as a verified available choice—and check the live model status before relying on it. (platform.claude.com)

If you searched for “Claude Code Opus 4” to start a project, choose a currently supported model instead. If you maintain an older integration that names Opus 4 directly, check its status and plan a migration. Claude Code model access and API access are different: a Claude Code subscription does not by itself establish that a model is available to your application.

Can you still select Opus 4 in Claude Code?

The Claude Code opus alias resolves to the newest Opus model on Anthropic’s API; the supplied documentation report identifies Opus 5.5 as that model. Selecting /model opus therefore selects the current Opus option, not a way to pin the session to Opus 4. (platform.claude.com)

Anthropic’s deprecation documentation says requests to retired models fail. It also says the listed dates apply to Anthropic-operated platforms, while Amazon Bedrock and Google Cloud’s Google-managed Claude service set their own retirement schedules. Because the current Opus 4 status row was not available in the retrieved official page text, check the model catalog for the platform you use before assuming either that Opus 4 still works or that a partner platform follows Anthropic’s schedule. (platform.claude.com)

What you mean What to do
Select a model inside Claude Code Use the model picker or /model opus for the current Opus option; this does not select Opus 4 specifically.
Call Claude from your application Use the Messages API with a model ID currently documented as supported. Verify Opus 4’s status before using any old identifier.
Use Claude through Bedrock or Google Cloud Check that provider’s model catalog and retirement schedule separately.

What Opus 4 was good at—and what that evidence can tell you

At launch on May 22, 2025, Anthropic positioned Opus 4 for coding, complex problem-solving, and long-running agent tasks. Anthropic reported 72.5% on SWE-bench and 43.2% on Terminal-Bench. These are historical results reported by Anthropic for Opus 4, not a current head-to-head comparison against today’s models. (anthropic.com)

Those launch results describe the model’s historical positioning; they are not a reason to choose it for a new deployment. Keep evidence about Opus 4 separate from later-model claims: commentary about Claude Code with Opus 4.5 and benchmark claims about Opus 4.1 do not establish Opus 4’s performance.

Practical choice: For complex coding or agent work, evaluate a currently supported Opus model on representative tasks from your own codebase. For routine coding, compare a currently supported Sonnet model as well. The launch claims alone do not establish which model is best for your workload.

Production API: use a currently documented model

Because Opus 4’s scheduled retirement date has passed and its specific current status was not available in the official page text retrieved here, don’t build a new integration around its old model identifier without checking that status first. Anthropic’s Python SDK documentation shows the Messages API pattern below using claude-opus-5-5. The official SDK guide documents installation, environment-variable authentication, the request fields, and parsing text content blocks. (platform.claude.com)

pip install anthropic
export ANTHROPIC_API_KEY="your-api-key"
import os
from anthropic import Anthropic

client = Anthropic(api_key=os.environ["ANTHROPIC_API_KEY"])

message = client.messages.create(
    model="claude-opus-5-5",
    max_tokens=1024,
    messages=[{"role": "user", "content": "Review this change for likely bugs."}],
)

for block in message.content:
    if block.type == "text":
        print(block.text)

The example follows Anthropic’s documented Python SDK usage. Keep the API key out of source control and browser-side code. Before migrating production traffic, test the replacement model on representative tasks and review your application’s error handling. (platform.claude.com)

Bottom line

“Claude Code Opus 4” refers to Anthropic’s original Opus 4 model, not the current model selected by the opus alias. Anthropic scheduled Opus 4’s API retirement for June 15, 2026, but the specific current status entry was not available in the official page text retrieved here; verify the status for your platform before relying on it. For a new API integration, use a model currently documented as supported and test it against your workload.

Sources

Model deprecations — Claude Platform Docs

Claude Platform release notes

Model configuration — Claude Code Docs

Python SDK — Claude Platform Docs

Using the Messages API — Claude Platform Docs

Introducing Claude 4

Contact us