EN ▾

Uncensored OpenAI-compatible API

Try with trial credit

Cheapest LLM API Providers: Real Cost Per Million Tokens

The cheapest llm api providers are not always the ones with the lowest sticker price. Real cost depends on your input to output ratio, hidden fees and whether the model can do the job. This guide shows how to compute it and where $0.15 and $0.50 per 1M tokens sits.

Last updated

Summary

  • Compare a blended rate instead of the headline input price alone.
  • Hidden costs include expiring credit, minimum top-ups, purchase fees and long-context surcharges.
  • Our rates are $0.15 per 1M input and $0.50 per 1M output, which blends to $0.22 at a 4 to 1 mix.
  • A cheap token is wasted if the model refuses your prompts. Test before you commit.
Coins flowing through a glass pipeline and weighing stages into a meter, picturing cost per million tokens

Start with a blended rate

Providers quote two prices per million tokens, one for input and one for output. Comparing only the input price flatters providers with expensive output, and the reverse. A single blended number fixes that.

blended rate = (input share x input price) + (output share x output price)

Measure your own mix from a day of logs. As an example, take a 4 to 1 split, meaning four input tokens for every output token. At $0.15 input and $0.50 output, the blended rate is (4 x 0.15 + 1 x 0.50) / 5 = $0.22 per 1M tokens. A chatbot that resends history is input heavy. A story generator is output heavy. Their blended rates, and so their cheapest provider, can differ.

For other vendors, check their current pricing page and plug their numbers into the same formula. Prices move often enough that any list in an article is stale quickly.

Kinds of providers and what each costs you

Instead of ranking brands, it is more durable to rank types:

TypeCost profileWatch for
Big cloud AI servicesPer token, tied to a cloud accountRegional rates, committed spend, bundled services
Model routersPer-model rates, one accountFees on credit, price differences between upstream hosts
Open-model hostsOften low per-token pricesRate limits, which model versions they serve
Single-model endpointsOne flat price pairOnly one model on offer
Self-hosting on rented GPUsHourly rent, not per tokenIdle time, ops work, scaling

Self-hosting looks cheapest per token only when the GPU stays busy. At low or spiky traffic you pay for idle hours, and the per-token API wins. The break-even depends on your traffic and your hardware, so calculate it with real numbers.

Hidden fees that change the ranking

Two providers with the same listed rates can cost very different amounts. Check each of these before choosing:

  • Credit expiry. Prepaid balance that expires is money lost. Ours never expires.
  • Fees on top-ups. Some platforms take a percentage when you add credit. Others, like us, add a bonus instead: +5% from $50, +10% from $100, +15% from $200.
  • Minimum purchase. A high minimum locks money up. Ours is $20, with whole amounts up to $500.
  • Charges for failed requests. We do not charge failed or refused requests.
  • Long-context tiers. Some models bill more once the prompt passes a size. Read the fine print for your prompt length.
  • Reasoning tokens. Models that think first can bill the thinking as output.
  • Rate limits. A low limit forces a more expensive plan or a queue.

Worked examples at $0.15 and $0.50

Three monthly workloads on our endpoint, with the arithmetic shown:

WorkloadInputOutputCost
Support bot30M tokens3M tokens$4.50 + $1.50 = $6.00
Story app10M tokens6M tokens$1.50 + $3.00 = $4.50
Batch tagging100M tokens1M tokens$15.00 + $0.50 = $15.50

The last row shows why the input price matters for batch jobs, while the story app shows how output dominates creative work. Apply your vendor shortlist's rates to the same three rows and the ranking appears in minutes.

You can also measure cost per request in code. The response includes a usage object, and the X-Balance-USD header shows the remaining balance after each call.

import os
from openai import OpenAI

client = OpenAI(
    base_url="https://api.providersapillm.com/v1",
    api_key=os.environ["UNCENSORED_API_KEY"],
)
r = client.chat.completions.create(
    model="uncensored",
    messages=[{"role": "user", "content": "List five names for a tavern."}],
)
u = r.usage
print(u.prompt_tokens / 1e6 * 0.15 + u.completion_tokens / 1e6 * 0.50)

Cutting the bill after you choose

Whichever provider you pick, your own habits move the total more than a few cents of difference in rates. Four changes pay off quickly.

Trim what you resend

In a chat app, input tokens grow with every turn because the history is resent. Keep the last several turns and a short summary of older ones. Suppose you serve 100,000 requests a month and cut 3,000 input tokens from each. That saves 300M tokens. At $0.15 per 1M that is $45 a month, with no loss in answer quality if the summary is good.

Shorten the system prompt

A 1,500-token system prompt sent 100,000 times is 150M input tokens, or $22.50. Rewriting it to 900 tokens saves 60M tokens, which is $9. Small numbers, but they repeat every month.

Cap the output

Output is the expensive side at $0.50 per 1M. If an answer needs 200 tokens and the model writes 500, you pay 2.5 times as much for it. Use max_tokens and ask for brevity in the instructions.

Stay inside the limits

Rate-limit errors waste time even when they are not billed. On a full key, plan around 8 concurrent requests and 300 per minute, and queue the rest. A streamed request holds its concurrency slot until the stream ends, so streaming UIs need fewer parallel jobs.

None of this depends on a provider. Apply it everywhere, then compare the rates again on the reduced usage. The ranking sometimes changes, because a provider with cheap input but costly output gains from short answers, and the opposite holds for one with cheap output.

Cheap only counts if it answers

A provider that refuses 10 percent of your prompts has an effective price about 11 percent higher, because you pay again for the retries, assuming refused calls are billed. That is one reason to read each provider's billing terms. For fiction, roleplay and companion apps for adults, refusals are the main hidden cost of filtered models.

Capability matters too. A tiny model at a tiny price may need three attempts to follow a format that a stronger model nails in one. Run 50 of your real prompts through each candidate, count the failures, and divide cost by successes. That figure is your real cost per result.

Our model is one open-weight model, run by an independent provider and tuned to answer without content refusals for lawful adult use. It handles up to 100,000 tokens of context. It does not generate images, audio or embeddings, so if you need those, you will need another provider alongside it.

A short decision rule

  1. Write down your monthly input and output tokens.
  2. Compute the cost at each shortlisted provider's current rates.
  3. Add fees, expiry losses and the retry rate.
  4. Test 50 real prompts for quality and refusals.
  5. Pick the lowest total, and keep a second provider ready for outages.

If our rates fit your numbers, the API key page gives you $0.50 of trial credit with no card, and the pricing page has the top-up table. For a broader look at host types, see the LLM inference providers comparison, and the docs cover the API itself.

Common questions

Which is the cheapest LLM API?

It depends on your input to output mix and the model quality you need. Compute a blended rate for each shortlisted provider using their current pricing.

Is self-hosting cheaper than an API?

Only when your GPUs stay busy. With low or spiky traffic, idle hardware often makes a per-token API cheaper.

What do your rates work out to?

$0.15 per 1M input tokens and $0.50 per 1M output tokens. At a 4 to 1 input to output mix, that is $0.22 per 1M tokens blended.

Does credit expire?

No. Credit on this API never expires, though the $0.50 trial credit is valid for 7 days.

Get your API key

Sign up, grab your key, update your base URL. Simple.

Start with trial credit

Use email and password; receive your key instantly.