induwara.lk
induwara.lkDevelopers · AI

AI Long-Context Pricing Calculator

Some models charge a premium once a prompt passes 200,000 tokens — and reprice the whole request, not just the overage. This calculator shows that jump before you ship, with the surcharge over a naive flat-rate estimate in USD and Sri Lankan rupees. No signup, sources cited below.

By Induwara AshinsanaUpdated Jul 11, 2026
Price your long-context requestUSD & LKR
List prices · verified Jul 2026

Tiered models reprice the whole request above 200K input tokens.

req

How many of these calls your app makes per month.

tok

Total prompt size — the number that decides the tier.

tok

Average completion length the model returns.

Prompt size
Rs

CBSL indicative — edit to today's rate.

Long-context tier (> threshold)500,000 input tokens > 200,000 threshold

The whole request is repriced at the long-context rate — not just the tokens over the threshold.

Per request
$1.55
Monthly cost (USD)
$1,550.00
Monthly cost (LKR)
Rs 465,000
Long-context premium
+$725.00
+87.88% vs standard rate

Per-request breakdown

ComponentTokensApplied rate /1MCost
Input500,000$2.50$1.25$1.25
Output20,000$15.00$10.00$0.30
Per-request total$1.55
Monthly total (1,000 req)Rs 465,000$1,550.00
Premium vs a naive standard-rate estimate+$725.00

Tier is decided by input tokens alone. A naive flat-rate estimate at the standard price would predict $825.00/month — the row above is how far the real bill lands beyond it.

Same workload, every model (cheapest first)

Cheapest option saves $1,350.00/mo (Rs 405,000)
ModelTierMonthly USDMonthly LKRvs selected
Google
flat$200.00Rs 60,000-87.1%
OpenAI
flat$825.00Rs 247,500-46.77%
OpenAI
flat$1,160.00Rs 348,000-25.16%
Google
long$1,550.00Rs 465,000
Anthropic
long$3,450.00Rs 1,035,000+122.58%

Tap any row to recompute the headline for that model. A flat-rate model can beat a tiered one once your prompt crosses 200K tokens — that flip is the whole point.

Vendor list prices snapshotted on 2026-07-11 — not a live feed.

How it works

A handful of long-context models — Gemini 2.5 Pro and the Claude Sonnet 4.5 1M-context beta among them — bill in two tiers. Below a 200,000-input-token threshold you pay the standard rate; above it, a higher long-context rate. The trap is that both Google and Anthropic apply the higher rate to the entire request, not only to the tokens beyond the threshold. There is no marginal, per-overage tier for long context at any listed vendor, so a prompt one token over the line reprices in full.

For a model with standard input/output rates stdIn / stdOut and long-context rates longIn / longOut (USD per 1M tokens), the calculator runs:

  1. Tier selection by input tokens: tier = inputTokens > 200,000 ? long : standard. The test is strict — exactly 200,000 tokens stays on the standard tier. Flat models skip this step entirely.
  2. Rate pick: inRate = long ? longIn : stdIn and likewise for output. The long tier changes both input and output pricing.
  3. Per-request cost: costIn = inputTokens ÷ 1e6 × inRate, costOut = outputTokens ÷ 1e6 × outRate, summed.
  4. Monthly = per-request × requests per month. LKR = USD × your editable CBSL rate.
  5. Premium: the same tokens are priced again at the standard rate, and the difference is the surcharge — surcharge = perReq − stdPerReq, as a percentage of the standard cost. It is $0 for standard-tier and flat models.

Every per-1M figure in the underlying data module carries an inline source URL, and the arithmetic is reconciled against an independent per-1,000-token formula so it can't drift. The comparison table reruns the whole calculation for every model on each input change and sorts cheapest-first — because a flat-rate model often undercuts a tiered one once the prompt is large enough.

Worked examples

RAG app on Gemini 2.5 Pro — the classic surprise

500K in · 20K out · 1,000 req/mo · std $1.25/$10, long $2.50/$15

  1. 500,000 > 200,000 → long-context tier (whole request reprices)
  2. costIn = 500,000 ÷ 1e6 × $2.50 = $1.25
  3. costOut = 20,000 ÷ 1e6 × $15 = $0.30
  4. perReq = $1.55 → monthly = $1.55 × 1,000 = $1,550.00
  5. naive std estimate = 0.5×$1.25 + 0.02×$10 = $0.825/req = $825.00/mo
  6. premium = $1,550 − $825 = +$725.00/mo (+87.88%)

Document analysis on Claude Sonnet 4.5 (1M beta)

300K in · 5K out · 500 req/mo · std $3/$15, long $6/$22.50

  1. 300,000 > 200,000 → long-context tier
  2. costIn = 300,000 ÷ 1e6 × $6 = $1.80
  3. costOut = 5,000 ÷ 1e6 × $22.50 = $0.1125
  4. perReq = $1.9125 → monthly = $1.9125 × 500 = $956.25
  5. naive std estimate = 0.3×$3 + 0.005×$15 = $0.975/req
  6. premium = $1.9125 − $0.975 = +$0.9375/req (+96.15%)

Below threshold — no premium (boundary case)

Gemini 2.5 Pro · 150K in · 10K out · 1,000 req/mo

  1. 150,000 ≤ 200,000 → standard tier, no premium
  2. costIn = 150,000 ÷ 1e6 × $1.25 = $0.1875
  3. costOut = 10,000 ÷ 1e6 × $10 = $0.10
  4. perReq = $0.2875 → monthly = $287.50
  5. premium = $0.00 (0%) — safely under the line
  6. Note: exactly 200,000 tokens also stays standard; the jump is at 200,001.

Frequently asked questions

Sources & references

Prices were last cross-checked against these sources on 2026-07-11. This tool is a calculator over a snapshotted price table, not a live feed — confirm the current rate on the official page before committing a budget.

Related tools

Rate this tool
Be the first to rate

Comments & feedback

Spotted a bug or want an improvement? Tell us — our team reviews every comment, and good ideas get built. Comments are public and anonymous.

Spotted a stale price, a new tier, or want another model added?

Email me at [email protected] — most fixes ship within 24 hours.