This page gets an Anthropic API key into WordPress and helps you choose between the two Claude models the plugin registers. The free plugin ships Claude 4.5 Haiku. Pro adds Claude 4.5 Sonnet, at 4.5 times the blended token price for the same fields.
When to pick Anthropic
Pick Anthropic when you already run a Console account, or when the rest of your stack is on Claude and one vendor invoice is worth something. On price it is the most expensive free-tier option the plugin registers: $2.00 per million tokens, against $0.56 for Gemini 3.1 Flash-Lite and $0.70 for GPT-4.1 mini. The plugin bundles no provider credit — every call is billed by Anthropic to your own account.
How to get an Anthropic API key
Create an Anthropic Console account
Go to console.anthropic.com and sign up. API access is billed separately from any Claude subscription, so an existing Claude plan does not carry over to the API.
Open the API keys page
From the Console, click your workspace name in the top-left, then Settings → API keys, or go directly to console.anthropic.com/settings/keys.
Create a new key
Click Create Key, name it something you will recognize later — wordpress-image-seo — and copy it. Anthropic shows the key once. Anthropic keys start with sk-ant-, which is useful for telling keys apart in a password manager.
Paste it into the plugin
In WP Admin, go to Image SEO → API Keys, paste the key into the Anthropic Claude API card and click Save Anthropic Key. The status badge flips to Configured, the key is stored encrypted, and the plugin verifies it with a live call.
Pick a Claude model
Open the AI Settings metabox on the plugin dashboard and choose from the AI Model dropdown — claude-haiku-4-5 on the free plugin, claude-sonnet-4-5 with Pro. The provider follows from the model id, so there is no separate provider switch to flip. Click Save Settings.
What Save and Test Key check
Saving no longer checks what a key looks like. Since 1.0.6 the only rejections are structural: an empty value, fewer than 8 or more than 512 characters, or a value containing spaces or control characters. Anything else is stored encrypted.
Verification happens after the save, as a zero-cost request to the provider’s models list — https://api.anthropic.com/v1/models for Anthropic. The Test Key button on the provider card repeats that request on demand and reports one of three results.
Test Key results
| Setting | Description |
|---|---|
valid
|
The provider accepted the key. The message reads "Key verified with the provider." |
invalid
|
Anthropic answered 400, 401 or 403. Its own error message is passed through unchanged — an identity-verification message means a real key on a blocked account, not a typo. |
unverified
|
The check could not complete: a network failure, a timeout or any other status. The key stays saved and can be tested again later. This is never reported as invalid. |
Results are cached for 5 minutes, or 1 minute after a network failure, so repeated clicks do not hammer the provider. A key that fails the test is still stored — the result reports, it does not block.
A key prefix is orientation, not validation
The sk-ant- prefix helps you recognize the key in a password manager. The plugin ignores it. Providers change their key formats — Google changed theirs in 2026 — so a format check rejects valid keys sooner or later. Only the live test tells you whether a key works.
Free-tier Claude models
Anthropic models in the free plugin
| Feature | Model id | Blended price / 1M tokens | Output cap, full run |
|---|---|---|---|
| Claude 4.5 Haiku Fast, cost-effective analysis — the description the plugin shows in the dropdown. | claude-haiku-4-5 | $2.00 | 1,024 tokens |
Claude 4.5 Haiku is the only Anthropic model the free plugin registers, and it is not the install default — a fresh install points at Gemini 3.1 Flash-Lite, so choosing Claude is always a deliberate change. One call returns alt text, filename, title and keywords together, inside a 1,024-token output cap.
Pro-only Claude models Pro
Pro adds Claude 4.5 Sonnet
With Image SEO Optimizer Pro active, Claude 4.5 Sonnet joins the Anthropic group in the AI Model dropdown, listed after Haiku — within each provider group the plugin puts the newest model last. Sonnet costs $9.00 per million tokens against Haiku’s $2.00, so 4.5 times as much for the same fields. Output varies between runs on either model; neither is deterministic.
Anthropic model added by Pro
| Feature | Model id | Blended price / 1M tokens | Output cap, full run Recommended |
|---|---|---|---|
| Claude 4.5 Sonnet Nuanced, brand-safe descriptions — the description the plugin shows in the dropdown. | claude-sonnet-4-5 | $9.00 | 1,024 tokens |
The id to use is claude-sonnet-4-5 — that is what the dropdown stores and what the REST API accepts under ai_model. Pro does not change the default model: a Pro site still runs Gemini 3.1 Flash-Lite until you pick Sonnet yourself.
These prices are per million tokens, not per image
The figures on this page are the blended per-million-token prices the plugin stores for each model and uses to estimate spend. Cost per image depends on image size, prompt length and how many fields you generate, so a per-image number would be a guess. The API Usage dashboard logs every call and shows what you actually spent. Checked against version 1.0.6 on 2026-08-12.
Next steps
Optimization Settings
Pick a model, batch size and request timeout for your chosen provider.
Prompts & Language
Tune the AI's voice with a prompt addon and pick from 133 output languages.
API Usage & Costs
Live dashboard of every AI call, per-provider breakdown, monthly spend.