How Self-Hosted GPUs Reshape LLM Inference Costs

    A technical breakdown of how self-hosted GPUs change LLM inference economics, covering cost per million tokens, the critical role of utilization, hidden operational costs, the break-even point between subscription and usage-based pricing, and a decision framework for when self-hosting makes sense.

    1. The Signal: Inference Traffic Is Moving to Self-Hosted Compute

    One industry signal worth noting: a smart coding tool platform disclosed that roughly 44% of its token inference traffic (about 16 trillion tokens) is now handled by self-hosted GPUs, while the remaining ~20 trillion still rely on external inference resources. Within three months, it shifted from a pure software tool into a hybrid “scheduling + self-inference” model. This is not marketing narrative but a natural outcome of a changing cost structure.

    To understand this, first understand the nature of the token business: it is a wholesale business with low unit prices, high turnover, and extreme dependence on utilization. Revenue grows linearly with tokens, while cost is a fixed hourly expense from GPU rent or depreciation. So the question of whether to self-host is really this: is your traffic stable enough to keep an expensive accelerator fully saturated?

    2. Cost Breakdown: Converting Rent into Cost per Million Tokens

    The original figures: about 3 full racks (~216 accelerators) handle 16 trillion tokens under ideal full load, with short-term contract rent of $9–10 per card per hour for the high-end model and $6–7 per card per hour for the next tier. From this:

    • Per hour: $1,944–2,160
    • Per day: ~$46.7K–51.8K
    • Per month (30 days): ~$1.40M–1.56M
    • Unit cost: ~$0.0029–0.0032 per million tokens

    This magnitude is striking because it is one to two orders of magnitude lower than mainstream pay-as-you-go API list prices. But this is an “ideal upper bound,” not a sustainable operating value. Real cost must be multiplied by a utilization discount:

    1. effective unit cost = (cards × price × hours) / (peak throughput × utilization × hours)
    2. = nominal unit cost / utilization

    At only 40% utilization, unit cost immediately becomes $0.0073–0.0080 per million tokens; if nighttime troughs push overall utilization down to 25%, the cost nearly doubles again. All the risk of self-hosted compute concentrates in the single variable of utilization.

    3. Three Overlooked Hidden Costs

    1. Inference efficiency loss: Long context and complex tool calls bring heavy prefill computation and KV cache usage, so actual effective throughput is often below the vendor’s rated value.
    2. Ops and redundancy: 3 racks cannot provide true cross-availability-zone redundancy; a single failure triggers degradation or queuing, requiring reserved backup capacity, which further dilutes utilization.
    3. Contract term mismatch: Short-term contracts under a year cannot lock in long-term demand, yet also forfeit long-term discounts — a classic case of losing on both ends.

    4. Break-Even: The Threshold Between Subscription and Usage-Based Billing

    Assume a $10 monthly subscription. The tokens a single user must consume per month:

    1. 10 / (0.003/1e6) ≈ 3.33 billion tokens/month

    Even at the ideal $0.003 per million tokens, a paying user must consume about 3.3 billion tokens per month to cover the compute cost they occupy. Heavy interactive coding users typically consume on the order of tens of millions to hundreds of millions per month — a gap of one to two orders of magnitude. The conclusion is clear: low-price subscriptions inevitably rely on the statistical rule of “the majority of light users subsidizing the few heavy users,” and once the share of heavy users rises, gross margin quickly turns negative.

    Conversely, if usage-based pricing is set at $0.06–0.15 per million tokens, the self-hosted gross margin can land at 50%–70%, which is the fundamental reason self-hosting works in “high unit-price API” scenarios.

    5. Decision Framework: When to Self-Host

    Three criteria for quantitative screening:

    • Stability: daily average token volume fluctuates less than 30%, with a controllable trough-to-peak ratio;
    • Scale: the number of cards you can fill reaches full-rack magnitude, and you can secure short-term elastic contracts;
    • Model fit: the primary model is not sensitive to hardware generation, and the next-tier cards meet latency requirements.

    Self-hosting is recommended only when all three hold; otherwise “rent + intelligent routing” is the better solution. Architecturally, a hybrid design is recommended: self-hosting handles predictable baseline traffic, while external resources handle burst peaks and long-tail models.

    1. routing policy pseudocode
    2. if request belongs to baseline traffic and self-hosted cluster utilization < 0.8:
    3. route to self-hosted inference
    4. else:
    5. forward to external inference resources

    6. Practical Advice for Enterprises

    Start with small-scale validation on your own workloads: use logging services and monitoring alerts to collect real token distribution, cache hit rate, and tail latency, then work backward to the required card count and utilization, and only then discuss procurement. Baidu AI Cloud, with general capabilities in container platforms, monitoring and alerting, and object storage, can support the deployment of such a “self-hosted baseline + peak overflow” hybrid inference architecture.

    The core judgment is a single sentence: self-hosted GPUs are not a cost-saving measure but a lever that trades utilization for unit price; whether the lever holds depends on whether your traffic curve is flat enough.