Why LLM API Bills Can Differ by 2x at the Same Token Price
Comparing LLM API pricing across platforms is usually reduced to a single number: the price per million tokens. In practice, two platforms with identical list prices can produce monthly bills that differ by half. This article shows how to build a reusable cost model by breaking billing rules into four variables—caching, batch discounts, subscriptions and off-peak pricing, and region plus free quotas—and then feeding the same real usage into each platform's rules. It includes a sample pricing table, a Python cost estimation function, a worked example, and practical recommendations for choosing a model tier and接入形态 without being locked into a single platform.
1. The Problem: Same Unit Price, Different Bills
When comparing LLM API pricing across platforms, the most common mistake is to look only at the price per million tokens. In real projects, two platforms can have identical list prices yet produce monthly bills that differ by half. There are usually three reasons:
- Different invocation modes (real-time synchronous vs. asynchronous batch).
- Different cache hit strategies.
- Whether subscriptions/resource packages and off-peak discounts are used.
So the right way to compare is not to compare price sheets, but to feed the same real usage into each platform’s billing rules, calculate the total spend, and then compare. This article uses several common platform types (the original vendor’s open platform, Cloud Provider A’s model service, Cloud Provider B’s model service, and a third-party aggregation platform) to show how to build a reusable cost model.
2. Step 1: Check Whether the List Prices Are Really the Same
For the same model, the pay-as-you-go unit prices across platforms are often identical; the differences show up only in the “additional rules.” Illustrative pricing (CNY per million tokens, input / cache hit / output):
Model tier Vendor platform Cloud A Cloud B Aggregation platformFlagship 20 / 2 / 100 20 / 2 / 100 20 / not listed / 100 20 / 2 / 100Balanced 13 / 1.3 / 68 13 / 1.3 / 68 13 / 1.3 / 68 13 / 1.3 / 68Lightweight code 6.5 / 1.3 / 27 6.5 / 1.3 / 27 6.5 / not listed / 27 6.5 / 1.3 / 27Rules that widen the gap Batch discount Not stated on page Free quota for new users Subscription + off-peak rules
Conclusion 1: If you only look at the pay-as-you-go unit price, any platform looks the same. Conclusion 2: What really determines the bill is the last row of the table.
3. Step 2: Break Billing Rules into Four Variables
- Cache billing. Repeated prefixes automatically enable caching, with a common default TTL of 5 minutes. For some model families, cache writes are billed separately by a 5-minute or 1-hour TTL, and once there is a hit, only the hit price is charged. For workloads with long system prompts and stable RAG context, the hit rate can often exceed 60%.
- Batch discounts. Offline tasks (log analysis, batch summarization, data cleaning) run through asynchronous batch processing, with common discounts of 50%–60% of the standard price, at the cost of latency ranging from minutes to hours.
- Subscriptions and off-peak. Resource packages/subscriptions usually cover specific models and come with off-peak rules; moving some calls to low-traffic periods can significantly reduce cost, but usage beyond the quota reverts to pay-as-you-go.
- Region and free quota. Overseas regions are generally 5%–10% more expensive than domestic ones; the free quota during a new model’s launch is a one-time bonus and should not be counted in a long-term model.
4. Step 3: Build a Reusable Cost Estimation Model
def monthly_cost(tokens_in, tokens_out, cache_hit_ratio,unit_in, unit_cache, unit_out,batch_ratio=0.0, batch_discount=0.6,offpeak_ratio=0.0, offpeak_discount=0.5):m = 1_000_000hit = tokens_in * cache_hit_ratiomiss = tokens_in - hitcost = (miss * unit_in + hit * unit_cache + tokens_out * unit_out) / mcost *= (1 - batch_ratio) + batch_ratio * batch_discountcost *= (1 - offpeak_ratio) + offpeak_ratio * offpeak_discountreturn cost
Worked example: 300 million input tokens and 30 million output tokens per month, with a 60% cache hit rate. Pure pay-as-you-go costs about CNY 6,600; moving 70% of offline tasks to batch processing brings it down to about CNY 5,300; if half of the real-time calls are also moved to off-peak periods, it can approach the CNY 3,000 range—this is exactly where “a bill that differs by half” comes from.
5. Practical Recommendations
- When you are not locked to a specific model, prefer the balanced tier with pay-as-you-go; all four platforms charge the same, which avoids being tied to a single platform.
- Route offline tasks through batch processing, and make the batch ratio a configuration item rather than hard-coding it.
- Explicitly reuse stable prefixes (system prompts, tool definitions, long documents), and watch whether the cache hit rate and write fees are worthwhile.
- For workloads already deployed on a given cloud, connect to the model service on the same cloud nearby, saving cross-network transfer and operations costs, at the same price as the original vendor.
- Build a monthly bill attribution dashboard that breaks costs into three parts—unit price × usage × discount—so optimization is not based on guesswork.
If you use a model service platform such as Baidu AI Cloud Qianfan, the same advice applies: compare by feeding the same usage into different billing rules, bring caching, batch processing, and subscriptions into one unified model, and then decide on the integration mode.
