Skip to main content

    AI Toolkit

    LLM Token Cost Calculator

    LLM token cost calculator comparing GPT, Claude, Gemini, DeepSeek and Mistral using open-source LiteLLM prices, with input, output and cached tokens.

    ComplimentaryResult on screen and by emailSources shown

    How do you calculate LLM API cost?

    Multiply monthly requests by input tokens and output tokens per request, divide by one million, and apply each model’s per-million price. Some providers charge less for eligible cached input tokens; availability and cache rules vary by model. This calculator applies prices from the open-source LiteLLM model price database to every model at once, so you can see the cheapest option for the same workload.

    AI Toolkit

    LLM token cost calculator

    Compare the monthly token cost of 11 leading models from OpenAI, Anthropic, Google, DeepSeek and Mistral. Prices come from the open-source LiteLLM pricing database, with input, output and cached tokens priced separately.

    Inputs

    Your workload

    Requests per month
    Workload preset
    Input tokens per request
    Output tokens per request
    Input served from prompt cache

    See your results

    This tool is complimentary. Tell us who you are and we'll show the result here and email you a copy.

    • Result shown here
    • A PDF report by email
    • One sign-up unlocks every tool

    Frequently asked questions

    Where do the token prices come from?

    From the open-source BerriAI/litellm model price file, widely used by AI engineering teams to track provider pricing. Prices change, so confirm with the provider before budgeting.

    Why are output tokens more expensive?

    Providers often price generated output differently from input. The ratio varies by model, so check both rates when comparing costs.

    How can I lower token cost?

    Shorten prompts, filter retrieved context, cache repeated prompts and route simple requests to smaller models, checking answer quality after each change.