Download the dataset
GET
https://apicostcalc.com/pricing.json
Full dataset — 387 LLM models + 34 API prices · 88KB · Updated monthly
curl https://apicostcalc.com/pricing.json
The file is a plain JSON with two top-level arrays: llm_models (LLM pricing per 1M tokens) and api_prices (provider service pricing). No auth required.
Data format
LLM models (llm_models array)
{
"id": "openai/gpt-4o",
"name": "GPT-4o",
"provider": "OpenAI",
"input_per_1m_usd": 2.50,
"output_per_1m_usd": 10.00,
"context_k": 128
}
| Field | Type | Description |
|---|---|---|
id | string | Slug: provider/model-name |
name | string | Model display name |
provider | string | Provider name (OpenAI, Anthropic, etc.) |
input_per_1m_usd | number | USD cost per 1M input tokens |
output_per_1m_usd | number | USD cost per 1M output tokens |
context_k | number | Context window in thousands of tokens |
API provider prices (api_prices array)
{
"provider": "Stripe",
"service": "card_processing",
"price": "3.1% + $0.30",
"metric": "per successful card charge",
"free_tier": "",
"last_verified": "2026-07-15"
}
Coverage
| Category | Providers covered | Count |
|---|---|---|
| LLM / AI models | OpenAI, Anthropic, Google, Mistral, Meta, DeepSeek, xAI, Cohere, Together AI, Fireworks + 20 more | 387 models |
| Payments | Stripe, Paddle, PayPal, Adyen, Braintree | 8 prices |
| Email API | SendGrid, Resend, Postmark, SES, Mailgun | 7 prices |
| SMS / Voice | Twilio, Vonage | 4 prices |
| Maps / Location | Google Maps, HERE, MapBox | 4 prices |
| Search / Data | Algolia, Brave Search, Bing Search, Alpha Vantage, CoinGecko | 6 prices |
| Other | ElevenLabs, Replicate, Deepgram, AssemblyAI and more | 5+ prices |
License & attribution
The data is available under Creative Commons BY 4.0. You can use it in products, research, and commercial applications. Required attribution:
Data source: APICostCalc.com
A link back to apicostcalc.com is appreciated but not required for machine use.
What you can do
- Use in your own product or SaaS
- Include in open-source projects
- Build npm/Python packages around it
- Use in research and academic work
- Redistribute with attribution
Data quality notes
- LLM prices updated monthly from official provider pricing pages
- Prices are standard public rates — enterprise pricing not included
- Some providers have complex tiered pricing; we show the base/starter tier
- Found an error? Report it →
Usage examples
Find the cheapest model for a workload
import json, urllib.request
with urllib.request.urlopen('https://apicostcalc.com/pricing.json') as r:
data = json.loads(r.read())
# Cost for 1M input + 200k output tokens
models = data['llm_models']
results = [
(m['name'], m['provider'],
m['input_per_1m_usd'] * 1 + m['output_per_1m_usd'] * 0.2)
for m in models if m['input_per_1m_usd'] > 0
]
results.sort(key=lambda x: x[2])
for name, provider, cost in results[:5]:
print(f"{provider}/{name}: ${cost:.4f}")
JavaScript / Node
const res = await fetch('https://apicostcalc.com/pricing.json');
const { llm_models } = await res.json();
const gpt4o = llm_models.find(m => m.id === 'openai/gpt-4o');
console.log(`GPT-4o input: $${gpt4o.input_per_1m_usd}/1M tokens`);
Need more?
The free dataset is updated monthly and covers the most common providers. If you need:
- Webhooks when prices change
- Price history (track how prices changed over time)
- Regional pricing differences
- Real-time updates
- Custom provider coverage
Contact us — we're building a Pro API tier.