Login Sign Up
Back to blogs
18 min read
Nov 17, 2026

Claude API: What You Actually Pay per Model and per Job

Claude API pricing in plain numbers: token prices for each Claude model, worked cost examples for real jobs, and how batch and prompt caching cut your bill.

Share Article

Claude API cover showing token prices, cost examples and batch and caching savings

The Claude API is billed by the token, and that one fact confuses a lot of people. A price like "$2 per million input tokens" sounds tiny, but it tells you nothing about what your app, script or agent will cost at the end of the month. I had the same problem the first time I wired Claude into a small tool for my own work, so in this guide I turn the official prices into real bills.

You will see the token price of each current Claude model from Anthropic's own pricing page, worked cost examples for real jobs like a support bot and a document pipeline, who each model suits, and the two features that cut costs the most: batch processing and prompt caching. I also explain how the API differs from the Claude chat apps, because that is where many people spend money they did not need to.

How Claude API Pricing Works in One Minute

Anthropic, PBC, the company behind Claude, charges for the text that goes in and the text that comes out, and both are measured in tokens. A token is a small piece of a word, and in English one token is roughly three quarters of a word. So 1,000 words is about 1,300 to 1,400 tokens, and a million tokens is a long book's worth of text.

There are two prices for every model, one for input and one for output. Input tokens are everything you send in a request: your system prompt, the user's message, the chat history and any documents. Output tokens are what Claude writes back. Output always costs more, about five times the input price on the current models, so long answers are where bills grow fastest.

There is no monthly fee for the Anthropic API itself: you add prepaid credits or a payment method in the Claude Console, create an API key, and pay as you go. Every response includes a usage block and a message ID, and the usage block shows the exact input and output tokens for that request, which is the number you are billed on. You can see the totals in the Console usage dashboard.

The extras that change the bill

A few things change the basic math, and the first is prompt caching, which lets you store a long, repeated prompt and pay much less each time you reuse it. The Batch API halves the price for jobs that do not need an instant answer. Tools such as web search and code execution have their own charges, and the pricing page also lists higher rates for US-only inference and a faster mode on the top models. I cover the ones that matter most below.

Claude Models and Their Token Prices

I verified these numbers on the official Claude pricing page and the API pricing docs today, both on https pages run by Anthropic. All prices are in US dollars per million tokens (MTok), and since Anthropic changes its line-up from time to time, always confirm on those pages before you plan a budget.

Table of Claude API model prices per million input and output tokens with batch discount
ModelInputOutputCache write (5 min)Cache read
Claude Fable 5.2$8$40$10$0.20
Claude Opus 5.5$4$20$5$0.20
Claude Sonnet 5.5$2$10$2.50$0.10
Claude Haiku 5.5 (prompts up to 100K tokens)$0.10$0.50$0.125$0.01
Claude Haiku 5.5 (prompts over 100K tokens)$0.50$2.50$0.625$0.05
Claude API pricing documentation page with per-model token prices
Screenshot: Pricing, Claude Platform Docs (platform.claude.com)

All four current models have a 1M tokens context window and can write up to 128K tokens in one response, according to the models overview, which Anthropic keeps updated as new LLM versions ship. They all read text and images and support tool use, so the main differences are quality on hard tasks, speed, and price.

Older Claude AI models still on the price list

Older Claude AI models are still listed, mostly for apps that were built on them. For example, Opus 4.8 and Opus 5 are listed at $5 input and $25 output, Sonnet 4.6 at $3 and $15, and Haiku 4.5 at $1 and $5. Some very old Claude 4 era models such as Opus 4.1 and Opus 4 cost $15 input and $75 output. Unless you have a reason to stay, newer models are both cheaper and stronger, so moving up usually lowers your bill.

Claude models overview page listing current Claude API models
Screenshot: Models overview, Claude Platform Docs (platform.claude.com)

Where the Claude API Counts Your Tokens

Whatever way you integrate Claude, before the examples it helps to know which endpoints bill you and how to measure tokens before you spend them. Every paid call goes to an https URL on api.anthropic.com, and the main one is a POST v1 request to the Messages endpoint at https://api.anthropic.com/v1/messages on the Claude Developer Platform. Your code implements every feature, from chat to agents, on top of this one endpoint. Each https request carries your API key for authentication in the x-api-key header, not an Authorization Bearer header like many other APIs use.

  • /v1/messages: the standard request, where you pay for input and output tokens and the response shows both in its usage block.

  • https://api.anthropic.com/v1/messages/count_tokens: counts the input tokens of a request before you send it, so you can estimate cost in your application without paying for a reply.

  • /v1/messages/batches: the Batch API, with the same models at half the token price and results later.

  • /v1/models: lists the Claude models your key can use with each model ID (with pagination for long lists), which helps you keep model names up to date.

Streaming does not change the price, because with streaming on, Claude sends the answer piece by piece over server-sent events, which feels faster to users, but you still pay for the same tokens. Streaming is free to turn on, so use streaming for any long answer a person is waiting for. The same is true for tool use: the tool definitions you send count as input tokens, so a long list of tools makes every request a bit more expensive.

OpenAI-style chat completions

Anthropic also offers an OpenAI SDK compatibility layer, so you can point an existing OpenAI client and its chat completions code at a Claude base URL, change the model name, and test Claude seamlessly without a rewrite, at the same token prices as the native API. For production, most developers move to the native v1 Messages API, because features like prompt caching and the Batch API are what bring the bill down, and the chat completions layer is meant mainly for testing.

Worked Cost Examples for Real Jobs

Here is where the per-million numbers turn into money, and I use simple, round numbers so you can redo the math for your own case. Each example uses standard prices without caching or batch, unless I say so.

Example 1: A customer support chatbot

Say your bot handles 10,000 conversations a month, and each one sends about 2,000 input tokens (instructions, a bit of history and the question) and gets about 400 output tokens back. That is 20 million input tokens and 4 million output tokens a month.

  • Haiku 5.5: 20 x $0.10 + 4 x $0.50 = $2 + $2 = about $4 a month

  • Sonnet 5.5: 20 x $2 + 4 x $10 = $40 + $40 = about $80 a month

  • Opus 5.5: 20 x $4 + 4 x $20 = $80 + $80 = about $160 a month

For simple FAQ answers, Haiku is often good enough, and the gap is huge, so I would test Haiku first, then move tricky questions to Sonnet with a simple rule in your code.

Example 2: Drafting 100 blog posts

Each post needs about 3,000 input tokens (a brief, an outline and style notes) and returns about 3,000 output tokens, which is a draft of roughly 2,200 words. For 100 posts that is 300,000 input and 300,000 output tokens.

  • Sonnet 5.5: 0.3 x $2 + 0.3 x $10 = about $3.60

  • Opus 5.5: 0.3 x $4 + 0.3 x $20 = about $7.20

  • Fable 5.2: 0.3 x $8 + 0.3 x $40 = about $14.40

The token cost of writing is small, and the real cost is your editing time. If you also want the drafts to rank, an SEO writing tool like SerpPal helps you check terms and structure against the pages that already rank.

Example 3: Summarizing 5,000 documents

Now a bigger job: 5,000 reports, each about 20,000 tokens long, with a 500-token summary each. That is 100 million input tokens and 2.5 million output tokens.

  • Sonnet 5.5 standard: 100 x $2 + 2.5 x $10 = $225

  • Sonnet 5.5 with the Batch API: half price, so about $112.50

  • Haiku 5.5 standard: 100 x $0.10 + 2.5 x $0.50 = $11.25

  • Haiku 5.5 with the Batch API: about $5.63

Input dominates this job, so the cheap input price of Haiku matters most, and since each prompt here is under 100K tokens, the lower Haiku rate applies.

Example 4: A long system prompt with caching

Imagine an app with a 50,000-token system prompt (product docs, rules and examples) that runs 1,000 times in a busy hour on Sonnet 5.5. Without caching, you pay for 50 million input tokens: $100.

With prompt caching, the first call writes the cache at $2.50 per million, which is about $0.13. The other 999 calls read it at $0.10 per million, about $5. Your total for that prompt is around $5.13 instead of $100, as long as the cache stays warm between calls. This is the single biggest saving I have seen for chat apps and agents.

Example 5: A coding agent session

Coding agents read a lot, and one long session on Opus 5.5 might use 2 million input tokens and 200,000 output tokens. At standard prices that is 2 x $4 + 0.2 x $20 = $12. If 1.8 million of those input tokens are cached reads of the same files, input drops to about $0.36 + $0.80, and the session costs about $5.16. Claude Code and other agent tools use caching for this reason.

If you run Claude Code on API credits instead of a subscription, the same math applies. A typical flow is to git clone a repository, open it in the terminal, and ask Claude Code to read files, plan a change, run commands and run tests. Each file it reads becomes input tokens, and a large repository clone can mean millions of tokens per day, so caching and a sensible model choice matter even more for coding workflows on big codebases.

Which Claude Model Suits Which Job

Price is only half the choice, because a cheap model that gets the answer wrong costs more in fixes and support. Here is how I would pick, based on Anthropic's own descriptions and my use.

  • Haiku 5.5: classification, tagging, routing, data extraction, simple automation and short replies at high volume. Fastest and by far the cheapest for prompts up to 100K tokens.

  • Sonnet 5.5: the default for most apps. Good writing, solid coding and fast responses at a fair price. Anthropic calls it the best mix of speed and intelligence.

  • Opus 5.5: long-running agents, agentic coding, complex coding tasks and knowledge work. Anthropic's models page recommends it for most workloads.

  • Fable 5.2: the hardest reasoning and long agent tasks where Opus still falls short. Use it only where the quality gain pays for the double price.

A pattern that works well: send every request to the cheapest model first, and only escalate when a check fails or the task is flagged as hard. Because all Claude models use the same Messages endpoint, switching is one model string in your code.

Ways to Pay Less for the Claude API

Five steps to lower Claude API costs with model choice, caching, batch and limits

Use the Batch API for work that can wait

The Batch API takes a large group of requests and returns the results later, usually within hours. In return you pay 50% of the normal token prices, which makes reports, tagging old data, translating product catalogs and nightly summaries good fits, while anything a user is waiting for in real time is not.

Cache what you repeat

If many requests start with the same long text, mark it for caching. On Sonnet 5.5, a cache read costs $0.10 per million tokens instead of $2, which is one twentieth. The cache write costs a little more than normal input, so caching only pays off when the same prefix is reused within the cache time.

Keep output short

Output tokens cost five times more than input on the current models. Ask for the format you need, such as "answer in 3 bullet points" or JSON with set fields, and set a sensible max_tokens. Cutting a 600-token answer to 300 tokens halves the output part of your bill.

Trim the context

Long chat histories quietly grow your input bill, so summarize older turns, send only the document sections that matter, and remove repeated instructions. A 1 million token context window is useful, but filling it on every request is expensive.

Set limits and watch usage

Use separate API keys for dev and production, set monthly spend limits in the Console, and log token usage per feature in your own app. When I did this, I found one debug feature using more tokens than the real product. Good API key management is part of cost control: keep your API key on your server, never in browser code or a public Git repo on GitHub, because a leaked key spends your credits. If a key leaks, delete it in the Console and create a new one right away. Teams can use an Admin API key to manage keys and pull usage reports, so founders and finance staff see the same numbers as developers.

Hidden Costs: Errors, Retries and Architecture

Token prices are only part of the real bill for any AI-powered product, because the way you build your application decides how many tokens you burn. A simple and safe architecture has your web or mobile interface talk to your own backend, and only that backend component calls the Claude API endpoints. That keeps your API key secret, keeps authentication on the server, and gives you one place for logging, limits and error handling across all API endpoints.

Good error handling saves money too, since a failed request with a 400 error usually costs nothing, but a loop that resends the same long prompt after every timeout can double your input tokens. Use a retry with growing delays for rate limit (429) and overloaded errors, and stop after a few tries. The official SDKs already retry common errors, so check their settings before you add your own retry logic on top.

When I test a new prompt in my dev setup on localhost, I first send it once with curl or the SDK, with the right headers for authentication, version and content-type set to application json, then read the usage block. That one test tells me the real token count, which I multiply by expected volume. This small step in your integration work prevents most budget surprises, and it takes five minutes. Log timestamps and token counts per request, and the insights you get show exactly which feature serves users and which only burns tokens.

Large datasets deserve the same care. A script that converts a whole CSV into prompts can quietly send millions of tokens, so test it on 100 rows first and multiply.

Incidents and outages: do failed calls cost money?

Like any cloud service, the Claude API sometimes has incidents with elevated errors, and Anthropic posts them on its status page. You pay for tokens that are actually processed, so check your Console usage after an incident rather than assume, and keep a robust retry plan, because automated retries that each partly stream an answer can add up. Build simple handling for incidents when the API is unavailable: back off, queue non-urgent work, and switch to a smaller model as an optional fallback while the service recovers.

Before deployment, whether on a simple server or a containerized deployment with Docker, add input validation so empty or giant inputs never reach the API, and store finished answers in a database so you do not pay twice for the same question. These small capabilities protect both functionality and budget.

If you are moving from OpenAI, remember that code calling v1 chat completions through the compatibility layer still bills at Claude prices. The savings from caching and batches only come once you move to the native API endpoints, so plan that switch early.

Claude API vs Claude Chat Plans

This is the part people mix up most, because the Claude chat apps (web, desktop and mobile) are sold as subscriptions, while the API is a separate developer product billed per token. A Pro subscription does not give you API access for your own app, and buying API credits does not unlock a paid chat plan.

Claude official plans and pricing page
Screenshot: Plans and pricing, claude.com

On the official pricing page today, Pro was $20 a month billed monthly, or $17 a month with yearly billing. Max started at $100 a month and, according to that page, includes $100 a month in API credits. Team plans are priced per seat. If you only want to use Claude yourself for writing, research or coding, a chat plan is usually simpler than the API. If you are building software, you need the API.

For a deeper look at the chat plans, read our Claude pricing guide, which compares Free, Pro, Max and Team in detail.

Where UST fits, honestly

This part is less technical but just as important for your budget.

UnlimitedSEOTools offers Claude chat access, not API access. There is a shared Claude AI plan and a private Claude option. Check each page for the current price and limits before you buy. These give you the chat app for your own writing and research. They do not give you an API key, so you cannot build apps, scripts or agents with them.

On a shared plan, other members use the same account, so never paste private code, client data or passwords into it, and remember the license is not in your name. If you want other AI and SEO tools in one place, compare the UST packages. Our guide to affordable SEO tools and the Google AI Pro free trial article cover more low-cost options.

A Quick Cost Checklist Before You Ship

  • Estimate input and output tokens per request, then multiply by monthly volume.

  • Price the job on Haiku, Sonnet and Opus, and test quality on real samples.

  • Cache any long prompt that repeats across calls.

  • Move non-urgent jobs to the Batch API.

  • Cap max_tokens and ask for short, structured output.

  • Set spend limits and alerts in the Console.

  • Recheck prices on the official page every few months.

Frequently Asked Questions

How much does one Claude API call cost?

It depends on the tokens: a call to Sonnet 5.5 with 2,000 input and 500 output tokens costs about $0.004 + $0.005, so roughly one cent. The same call on Haiku 5.5 costs a small fraction of a cent.

Is there a free tier for the Claude AI API?

The API is pay as you go. You can try Claude for free in the chat app, and the official pricing page says the Max plan includes monthly API credits. Check the Console for any current starter credits.

Why is output more expensive than input?

Generating new text takes more compute than reading it. On the current models output costs five times the input price, so keeping answers short is one of the easiest savings.

Does prompt caching change the answer quality?

No. Caching only stores the repeated start of your prompt so it is cheaper and faster to reuse. Claude still reads it the same way.

Can I use a Claude chat subscription to call the API?

No. Chat plans and the API are separate products, and to call the API you need a Console account, an API key and credits. Shared chat access, such as the plans on UST, never includes an API key.

Which model gives the best value?

Broadly speaking, for most apps Sonnet 5.5 gives the best balance of quality and cost. For very high volume and simple tasks, Haiku 5.5 is far cheaper. Save Opus 5.5 and Fable 5.2 for work where quality really pays.

Final Thoughts

The Claude API is cheap per request and easy to overspend at scale. Price your job on two or three models, test quality on real samples, and use caching and the Batch API wherever they fit. With those habits, most small apps cost a few dollars a month, and even large jobs stay predictable.

If you only need Claude for your own writing and research, a chat plan is the simpler choice, and our Claude pricing guide helps you pick one. If you are building, start with Sonnet, measure your tokens, and let the numbers guide you.