Cost per million tokens (per Mtok)
The standard unit LLM providers price in: USD per 1,000,000 tokens.
Quoted separately for input and output. To get a request's cost, divide token counts by 1,000,000 and multiply by the per-Mtok rate for each direction.
Why it matters
It's the rate you multiply everything by, so a small change — a new model, a provider discount — ripples straight through to your margin on every single customer.
Example
At $2.50/Mtok input, a 400k-token prompt costs 400,000 ÷ 1,000,000 × $2.50 = $1.00. Add the output side the same way to get the full request cost.
Calculate it with the free margin calculator →
Related terms