QuantoCOSTA DAVVERO

How much does it cost to use a pay-as-you-go AI API?

A workload of one million input tokens and one million output tokens costs from USD 0.60 to USD 60 on the verified price lists; a Claude Sonnet 5.5 example costs USD 12.

Verifiable answer

A workload of one million input tokens and one million output tokens costs from USD 0.60 to USD 60 on the verified price lists; a Claude Sonnet 5.5 example costs USD 12.

How much does it cost to use a pay-as-you-go AI API?
US$12 / 1 million input tokens + 1 million output tokens
US$0.60 – US$60
Global API price lists in US dollars
19 October 2026
Confidence: High
Input tokens sent to the model; Output tokens produced by the model; Three scenarios calculated from Anthropic standard prices; Cross-check against the official OpenAI price list
Prompt caching and stored tokens; Web search, containers and other paid tools; Application development, hosting and monitoring; Taxes, foreign-exchange costs and payment fees
Chosen model; Input and output token volume; Cache use and cache duration; Tools such as web search or containers; Request volume and batch processing
2 sources

Short answer

APIs are not priced like a monthly subscription: the bill depends on the model, tokens sent and tokens generated. To compare price lists, this guide uses the same workload of one million input and one million output tokens.

A pay-as-you-go AI API is billed by use, not like a monthly ChatGPT or Claude subscription. Each request sends tokens to a model and receives tokens back; the two flows are priced differently. A short prompt with a long answer can therefore cost far more than the sent text alone suggests. OpenAI and Anthropic publish prices per million tokens, but their many models and options can make the final bill hard to read. This guide uses one concrete workload: one million input tokens and one million output tokens. On Anthropic’s list, that workload costs USD 0.60 with Claude Haiku 5.5, USD 12 with Claude Sonnet 5.5 and USD 60 with Claude Fable 5.1. These are not quotations for a whole application. They show how model choice and output volume change spending. Tools such as web search, containers and storage can add separate charges.

What is included

  • Input tokens sent to the model
  • Output tokens produced by the model
  • Three scenarios calculated from Anthropic standard prices
  • Cross-check against the official OpenAI price list

What is not included

  • Prompt caching and stored tokens
  • Web search, containers and other paid tools
  • Application development, hosting and monitoring
  • Taxes, foreign-exchange costs and payment fees

How the price breaks down

How the price breaks down: Using a pay-as-you-go AI API
One-million-input and one-million-output workload with Claude Haiku 5.5USD 0.10 for input plus USD 0.50 for output per million tokens.Compulsoryone-offUS$0.60
One-million-input and one-million-output workload with Claude Sonnet 5.5USD 2 for input plus USD 10 for output per million tokens.Compulsoryone-offUS$12
One-million-input and one-million-output workload with Claude Fable 5.1USD 10 for input plus USD 50 for output per million tokens.Compulsoryone-offUS$60

What the price depends on

  • Chosen model
  • Input and output token volume
  • Cache use and cache duration
  • Tools such as web search or containers
  • Request volume and batch processing

Hidden costs

  • Output is often more expensive than input and grows with verbose answers
  • A more capable model can multiply the bill at the same volume
  • Caching, tools and web search can have separate charges
  • Long prompts, attachments or conversation history sent on every call add billed tokens

Three realistic scenarios

Economy

US$0.60

One million input and one million output tokens with Claude Haiku 5.5 at Anthropic’s standard prices.

Typical

US$12

The same workload with Claude Sonnet 5.5: USD 2 of input and USD 10 of output.

High capability

US$60

The same workload with Claude Fable 5.1: USD 10 of input and USD 50 of output.

How to spend less

  1. Measure input and output tokens separately before selecting a production model.
  2. Set a sensible answer-length limit because it directly reduces billed output.
  3. Use a lighter model for classification, extraction or routing where its quality is sufficient.
  4. Reuse prompts and context through caching only after comparing the provider’s stated write and read costs.
  5. Set budgets and alerts in the provider dashboard before connecting the API to an automated workflow.

Frequently asked questions

Does an API cost the same as a ChatGPT or Claude subscription?

No. An app subscription and API consumption are separate products. API use is billed by tokens, model and tools. Holding a personal subscription does not automatically make API requests included, so an application budget must be calculated from the API price list.

What are input and output tokens?

Input tokens are units of text, instructions and context sent to the model. Output tokens are the units generated in its answer. OpenAI and Anthropic price them separately; output costs more than input for many models. A long answer can therefore drive the bill even when the prompt is brief.

Why is the typical figure USD 12?

USD 12 is the cost of a stated workload: one million input tokens plus one million output tokens with Claude Sonnet 5.5, at standard prices of USD 2 and USD 10 per million. It is not an average across providers or a monthly forecast; it is a repeatable, verifiable scenario.

Does caching always reduce the cost?

It can reduce cost when the same context is reused, but it has its own rules. Anthropic lists a charge to write cache entries and a lower charge to read them; the benefit depends on how often the content is reused and for how long. Measure real requests first, as lightly reused caching may not deliver the expected saving.

What should I add to the token price?

It depends on the application. OpenAI and Anthropic list separate charges for some features, such as web search, storage, containers or server tools. You should also allow for hosting, databases, monitoring, taxes and currency conversion. This guide deliberately isolates tokens so infrastructure costs are not mistaken for model costs.

Sources and methodology

How we worked it out

We opened OpenAI’s and Anthropic’s official API price lists on 19 October 2026. Both quote input and output by the million tokens in US dollars, so we did not convert figures to euros. For comparable scenarios, we add the cost of one million input and one million output tokens for each Anthropic model: USD 0.10 plus USD 0.50 for Haiku 5.5, USD 2 plus USD 10 for Sonnet 5.5, and USD 10 plus USD 50 for Fable 5.1. The USD 12 typical figure is an example, not a market average. We exclude caching, batch processing, web search, images, audio and server tools because each has its own rate and depends on the application design.

Why this confidence level

Confidence is high because token rates and surcharges are published directly by OpenAI and Anthropic. A particular application’s bill is still variable: it depends on the request design, model choice and extra tools outside these scenarios.

  1. OpenAI API prices per million tokens, including input, output and additional tools.

    Pricing | OpenAI API (opens in a new tab)

    OpenAI · Official tariff · Verified on 19 October 2026

    Opened on 19 October 2026. The price list states that input and output are billed at the selected model’s rates.

    Authority4/5

  2. Anthropic API prices per million tokens and the uplifts for caching, tools and fast mode.

    Pricing | Claude Platform Docs (opens in a new tab)

    Anthropic · Official tariff · Verified on 19 October 2026

    Opened on 19 October 2026. The list states USD prices and distinguishes input from output tokens.

    Authority4/5

Read the methodology

Revision history

First published on 19 October 2026 with token prices verified on OpenAI and Anthropic’s official price lists.

19 October 2026
19 October 2026
19 November 2026

What did you actually pay?

Reader reports help us see when a published price has drifted from the real one. No report changes our figures automatically: we read them, check them against the sources, and only then update a guide.

We do not publish your email address and do not use it for anything else. The rest of the report may be published in aggregate, anonymous form.

Related guides

How much does ChatGPT Pro cost?

US$200 / month
US$200

Verified on Aug 2026 · 1 source

How much does Claude Pro cost?

US$20 / month
US$17 – US$20

Verified on Jul 2026 · 2 sources

How much does GitHub Team cost?

US$4 / user per month
US$0 – US$21

Verified on Jul 2026 · 3 sources