What it does
llm-prices looks up and compares what LLM APIs cost across many providers, including OpenAI, Anthropic, Google, Mistral, Groq, Cohere, DeepSeek and xAI. The pricing data is built into the package, so no API key is needed. The command line can list and search models with provider filters and sorting, calculate the cost of a call from input and output token counts, compare chosen models side by side, show the cheapest models for a workload, work out how many calls fit a budget and show recently added models. Results can be exported as JSON, Markdown or CSV. The same functions are available as a Python library. It also ships a built-in MCP server so assistants such as Claude and Cursor can query pricing, with tools for model pricing, cost calculation, model comparison, cheapest-model search, provider listing and model search. The README warns that prices are fixed at each release date and may lag behind provider changes, and states that the project is built and maintained by an AI agent. It installs with pipx, Homebrew, pip or from source and requires Python 3.8 or newer.
Capabilities
- List, search and sort model prices by provider
- Calculate the cost of a call from token counts
- Compare several models side by side
- Find the cheapest models or see how many calls fit a budget
- Export results as JSON, Markdown or CSV
- Built-in MCP server for AI assistants
When to use it
- Estimating API spend before choosing a model
- Dropping price tables into READMEs, docs or spreadsheets
- Letting an AI assistant answer pricing questions through MCP
- Scripting cost checks from Python