Guilds AI / Blog

,

How Much Do AI Tokens Cost? API Pricing and Examples

Laptop with a conceptual AI token pricing dashboard beside a calculator and symbols for API usage and cost optimization.

AI tokens can cost as little as $0.10 per million input tokens and $0.50 per million output tokens on GPT-6 Luna. More capable models can charge several dollars for the same input and tens of dollars for output. Your actual bill depends on the model, the tokens it processes and generates, the pricing tier and any additional services. A million input tokens and a million output tokens are two separate quantities, not a single million-token purchase. Video output can have a different billing structure; our AI video generation API guide compares per-second and token-based examples. For an example of fixed subscription costs and per-site reseller fees, see our white label AI website builder guide.

How much do AI tokens cost per million?

The following examples use standard paid text API rates in US dollars, checked against the official OpenAI, Claude and Gemini developer documentation on December 4, 2026. They represent selected models, not the cheapest and most expensive models across the entire market. The rates assume ordinary uncached input and no higher-priced long-context, speed or regional tier.

ModelInput / 1MOutput / 1M1M input + 200K output
GPT-6 Luna$0.10$0.50$0.20
Gemini 4 Hydrogen$1.50$7.50$3.00
GPT-6.2 Sol$2.00$10.00$4.00
Claude Sonnet 5.5$2.00$10.00$4.00
Claude Opus 5.5$4.00$20.00$8.00
Claude Fable 5.2$8.00$40.00$16.00

At the same assumed token volume, GPT-6.2 Sol and Claude Sonnet 5.5 have identical base token costs. That does not establish identical bills for real tasks: their tokenizers, generated reasoning and tool interactions may differ. The pricing calculators from Helicone and AI Cost Estimator illustrate the value of comparing a consistent workload across models. Their retrieved snapshots contained older model prices, so the table above uses current provider documentation instead. For provider-specific rates, see our OpenAI API cost guide and Claude API pricing guide.

What counts as a billable AI token?

A token is a unit of model input or output. A tokenizer can split a word into several tokens or combine characters into one token. Punctuation, whitespace, code, numbers and different languages affect the count. Word counts can provide a rough planning estimate, but they are not an invoice. Use the selected provider’s token-counting endpoint or tokenizer where available.

Token categoryWhat it can include
Ordinary inputSystem instructions, user prompts, retrieved documents and conversation history
Cached inputPreviously processed prompt content eligible for a discounted read rate
Cache writesInput processed to establish a reusable cache, where charged
OutputGenerated text and billable internal reasoning, according to the model
Other modalitiesImage, audio or video usage measured by the applicable service

A user might send a short question while the application attaches a long system instruction and several retrieved documents. The entire submitted context matters. Likewise, the visible answer may be shorter than the billed output because a reasoning model can generate internal tokens. Check the provider’s usage response rather than estimating output from the visible characters alone.

How to calculate AI token costs

For a standard text request without caching, calculate the input and output components separately.

Request cost = (input tokens × input rate + output tokens × output rate) ÷ 1,000,000. The rates in this formula are dollars per million tokens.

For example, a GPT-6.2 Sol request with 3,000 ordinary input tokens and 800 billed output tokens costs $0.006 for input and $0.008 for output. The total is $0.014, or 1.4 cents, excluding other charges. At 5,000 identical requests, the estimated cost is $70.

To build a spreadsheet, put input tokens in A2, output tokens in B2, input rate in C2 and output rate in D2. Use =(A2*C2+B2*D2)/1000000. Add the number of calls in E2 and multiply the result by E2 if the row describes average usage per call. If the token counts are already monthly totals, do not multiply them by request count again.

Monthly cost examples for three workloads

These three fictional workloads use assumed token counts, not measurements from live API calls. They are useful for understanding how volume and output length change a bill.

WorkloadMonthly callsInput / callOutput / callGPT-6 LunaGPT-6.2 SolClaude Fable 5.2
Classification100,00050050$7.50$150.00$600.00
Support drafting10,0002,500500$5.00$100.00$400.00
Document analysis1,00020,0002,000$3.00$60.00$240.00

For support drafting on GPT-6.2 Sol, the monthly totals are 25 million input tokens and five million output tokens. The input cost is $50 and the output cost is $50, producing a $100 model bill. Output represents only one-sixth of these tokens but half of the cost.

A cheaper model is not necessarily cheaper per successful task. If a smaller model requires multiple attempts or manual corrections, include those in the comparison. Measure acceptance rates using a representative evaluation set; our AI evaluations guide explains how to structure those checks.

Caching, batch processing and long prompts

Prompt caching can reduce repeated input costs, especially when many requests share a long instruction or document. Cache creation, reading and retention can have distinct prices. GPT-6.2 Sol’s short-context standard rates are $2 per million ordinary input tokens, $2.50 per million 30-minute cache-write tokens, $0.10 per million cache-read tokens and $10 per million output tokens.

Consider 100 requests sharing a 10,000-token prefix, with an additional 1,000 ordinary input tokens and 300 output tokens per request. With no caching, the estimated cost is $2.50. If the first request writes that prefix and the other 99 read it from cache, the cost is $0.025 for the write, $0.099 for reads, $0.20 for other input and $0.30 for output: $0.624 in total. This assumes the cache stays valid, all intended hits occur and no other charges apply.

Langfuse’s cost-management guidance highlights a useful accounting distinction: provider usage fields do not always describe exclusive categories. If a total input count includes cached tokens, subtract the relevant cached portion before applying its separate rate. Do not subtract it twice when a provider already reports the categories separately.

Batch or flexible processing can offer lower rates for eligible workloads that tolerate delays. Long prompts can have the opposite effect. GPT-6.2 Sol applies higher rates to an entire request above 272,000 input tokens, not only the excess. Portkey’s pricing guide illustrates why a single universal discount or multiplier is unreliable; some of its historical rate examples have changed since publication. Always confirm the current model rules.

Costs beyond basic text tokens

For speech generation, see our text-to-speech API guide for character-based pricing and streaming costs.

Token prices do not describe every possible AI charge. Search calls, tool execution, stored cache context, audio, generated media and hosting may be metered differently. An agent can also issue several model requests for one user-facing action. Track the complete sequence, including retries, rather than charging the user-facing action as if it were a single request.

Free API tiers and consumer subscriptions are not interchangeable with production token balances. Check the applicable account and regional terms. Our Google AI Studio vs ChatGPT guide explains the difference between interactive experimentation and separately billed application usage.

How to reduce AI token costs

First, measure actual consumption by model and feature. Record the request identifier, effective model, input and output buckets, cache activity and additional service charges. Compare the totals against the provider invoice. Use one authoritative record for each call so logs from multiple layers do not inflate the total.

Then reduce unnecessary context, limit irrelevant retrieval, select smaller models for tasks they can reliably handle, reuse stable prefixes and batch eligible work. Keep a budget for retries and unusual requests. Set alerts and enforce request limits in your own application where necessary; a billing alert is not necessarily an immediate hard spending cap.

Evaluate quality after each change. A cost reduction that causes incorrect classifications or unreliable code is not a genuine efficiency improvement. Use cost per accepted result as the primary business measure, while separately monitoring latency and reliability.

Frequently asked questions

How much does 1,000 AI tokens cost? At $2 per million input tokens, 1,000 input tokens cost $0.002. At $10 per million output tokens, 1,000 output tokens cost $0.01. The actual rate depends on the selected model and tier.

How much does one million AI tokens cost? The answer depends on whether they are input, output, cached or another category. For example, one million GPT-6 Luna ordinary input tokens cost $0.10 at the checked standard rate.

Are AI tokens the same as words? No. A token is determined by the tokenizer, and the same text may produce different token counts across models.

Do reasoning tokens cost money? They can be billed as output or under other model-specific rules even when they are not displayed to the user.

Can I use AI tokens for free? Some services offer limited free usage. Eligibility, quotas and data terms differ. Check billing settings before starting a paid API workload.