Skip to content

Calculator

LLM API cost calculator

One call costs its fresh input tokens times the input price, plus its cached tokens times the cached price, plus its output tokens times the output price, each per million tokens. Enter your sizes to see it per call, per day and per month.

Checked 29 October 2026

per million input tokens on DeepSeek V4.1 Flash Uncensored
$0.45
per million cached input tokens
$0.011
a month for the coding agent preset
$26.06

Work out your cost

Start from

DeepSeek V4.1 Flash Uncensored

$5.36 a month

Per call
$0.0018 · 1.8 credits
Per day
$0.18
Where the money goes: Fresh input 76%Cached input 0%Output 24%

$10 of credits lasts 55 days

GLM 5.3 Flash Uncensored

$2.29 a month

Per call
$0.00076 · 0.76 credits
Per day
$0.08
Where the money goes: Fresh input 79%Cached input 0%Output 21%

$10 of credits lasts 131 days

DeepSeek V4.1 Flash Uncensored: $5.36 a month; GLM 5.3 Flash Uncensored: $2.29 a month

Prices come from the same table as the bill, and a call is billed to a millionth of a credit; 1,000 credits are $1. A month is 30 days.

The prices it uses

ModelPer 1M tokens inPer 1M cached inPer 1M tokens out
DeepSeek V4.1 Flash Uncensored$0.45 (450 credits)$0.011 (11 credits)$1.75 (1,750 credits)
GLM 5.3 Flash Uncensored$0.20 (200 credits)$0.04 (40 credits)$0.65 (650 credits)

These are the prices the API bills, read from the same table. 1,000 credits are $1. Pricing and billing has the rest.

How the cost is worked out

Take the coding agent preset on DeepSeek V4.1 Flash Uncensored: 40,000 tokens in, 90% of them cached, 400 out.

  1. Fresh input: 4,000 tokens × 450 credits per million.
  2. Cached input: 36,000 tokens × 11 credits per million.
  3. Output: 400 tokens × 1,750 credits per million.
  4. Together that is 2.896 credits, or $0.0029 a call. The bill keeps the fraction and carries it to the next call, so nothing is rounded up.
  5. At 300 calls a day, it comes to $0.87 a day and $26.06 over 30 days.

Why the cached share matters

An agent or a long chat sends the same start on every call: the instructions, the tools, the story so far. The part a model has just read comes from its cache and is priced apart. On DeepSeek V4.1 Flash Uncensored a cached token costs $0.011 per million against $0.45 fresh, about 41 times less.

The same agent call with nothing cached costs $0.02 instead of $0.0029: $168 a month instead of $26.06. Keep the start of your prompt the same from call to call and add new text at the end, and most of it stays cached.

GLM 5.3 Flash Uncensored prices a repeated start the same way, at $0.04 per million. Every call’s usage.prompt_tokens_details.cached_tokens says how much was cached.

Finding your token counts

  • A token is about four characters of English, or three quarters of a word. A page of text is around 500 tokens.
  • Tokens in are everything a call sends: the system prompt, the whole chat history, tool definitions and pictures. They grow with every turn of a chat.
  • Tokens out are the reply. With thinking on, the thinking counts as output too. See Thinking.
  • For real numbers, send a few calls with the free test key or your own, and read usage in each reply. The console lists every call’s tokens and credits.

Questions

How do I calculate the cost of an LLM API call?

Multiply the fresh input tokens by the input price, the cached input tokens by the cached price and the output tokens by the output price, each per million tokens, and add the three. On nokeep the total is worked out to a millionth of a credit, and the fraction carries to your next call.

Why does output cost more than input?

The model writes output one token at a time, which takes far more computing than reading input all at once. That is why output is priced three to four times higher here, and why short replies keep costs down.

Is a month 30 days?

Yes. Per month is the per-day cost times 30.

How do I pay?

Buy credits in the console; calls draw them down. Auto top-up can refill them when they run low, so calls never stop. There is no subscription and no monthly minimum.

Can I set a spending limit?

Yes. Each key can have a daily cap in credits, and a key can’t spend more than the credits you bought. See Keys and caps.