Get API key

Kimi Code API Pricing vs Pay-as-You-Go Tokens

If you are comparing plans before you commit, the cleanest way to see your real cost is to count tokens. This page prices common jobs at $0.15 per 1M input tokens and $0.50 per 1M output tokens.

Updated

Isometric illustration of token cubes flowing into a cost meter beside a glass piggy bank

The short answer on cost

People who search for kimi code api pricing usually want one number to plug into a budget. For Kimi's own plans, check their current pricing page, because plan names, limits and prices change and I will not guess at them here. What this site can give you is a precise number for the alternative you are reading about: an OpenAI-compatible text API with one model, billed per token.

The rates are $0.15 per 1M input tokens and $0.50 per 1M output tokens. There is no subscription and no monthly minimum. You add prepaid credit, each request deducts what it used, and the credit never expires. Failed or refused requests are not charged, so an error response does not cost you anything.

Two things are worth saying plainly before the math. First, there is no free unlimited tier here. Second, the only free money is the one-time trial: $0.50 of credit, claimed with one click on the API key page after sign-up, valid for 7 days, no card needed. Everything past that is paid from credit you add yourself.

How tokens turn into dollars

A token is a chunk of text, roughly three to four characters of English. Your prompt is counted as input tokens. The reply the model writes is counted as output tokens. Output is priced higher than input because generating text is the expensive part.

The formula for one request is simple:

cost = input_tokens x 0.15 / 1,000,000 + output_tokens x 0.50 / 1,000,000

Chat history counts too. If you resend ten earlier messages with every turn, those messages are billed as input each time. That is the single biggest reason a bill ends up higher than a first guess, and it is why long agent loops cost more than they look like they should.

The API returns an X-Balance-USD header on responses, so you can watch your remaining credit in code instead of opening a dashboard. Log it once per request while you are testing and you will learn your real per-call cost within an hour.

Worked examples

Here are four jobs priced exactly. Each row is input tokens times $0.15 per 1M plus output tokens times $0.50 per 1M.

JobInputOutputCost per request
Short chat reply1,000300$0.00015 + $0.00015 = $0.0003
Chat turn with history2,000500$0.0003 + $0.00025 = $0.00055
Coding question with files pasted in20,0001,000$0.003 + $0.0005 = $0.0035
Near-full context window96,0004,000$0.0144 + $0.002 = $0.0164

Now scale them to a month. A small chat product handling 100,000 turns of the 2,000/500 size uses 200M input tokens and 50M output tokens. That is $30 for input plus $25 for output, so $55 in total.

A solo developer who asks the 20,000/1,000 coding question 50 times a day for 30 days makes 1,500 calls. That is 30M input tokens ($4.50) and 1.5M output tokens ($0.75), so $5.25 for the month.

Even filling the context window on purpose costs under two cents a call. The window is 100,000 tokens shared between prompt and completion, which is why the last row uses 96,000 plus 4,000.

What a top-up buys

You can add any whole amount from $20 to $500. Larger top-ups carry a bonus on the credit you receive:

  • $20 to $49: no bonus, so $20 gives $20 of credit.
  • $50: +5%, so $52.50 of credit.
  • $100: +10%, so $110 of credit.
  • $200: +15%, so $230 of credit.

Measured in the chat turn from the table, $20 covers about 36,000 turns ($20 divided by $0.00055 is 36,363). Measured in the coding question, $20 covers about 5,700 calls ($20 divided by $0.0035 is 5,714). For most individual developers the first top-up lasts weeks, and since credit never expires, a month of light use costs you nothing extra.

Payment is by card (Visa, Mastercard, Apple Pay, Google Pay) or crypto (USDT on TRC20, USDC on Base). The pricing page lists the same rates and bonus tiers if you want to check this section against the source.

A worked monthly budget

Here is how a first month might be planned. Say you run a small support-style assistant and expect 1,200 conversations. Each conversation has about six turns, and each turn averages 1,500 input tokens (history plus the new message) and 400 output tokens. That is 7,200 turns, so 10.8M input tokens and 2.88M output tokens.

The input side costs 10.8 times $0.15, which is $1.62. The output side costs 2.88 times $0.50, which is $1.44. The month comes to $3.06. A first $20 top-up would cover that traffic more than six times over, and whatever is left carries into the next month because credit does not expire.

Now stress the plan. If history grows and each turn averages 6,000 input tokens, the input side quadruples to $6.48 while output stays at $1.44, for $7.92. The lesson is that input growth is what moves the total, and the fix is to trim what you resend, not to cut replies short.

Trial credit and what it covers

The $0.50 trial is meant for testing, not for production. At the 2,000/500 chat size it covers about 900 requests ($0.50 divided by $0.00055 is 909). That is plenty to check that the API answers the way you need, to try streaming, and to test a tool-calling flow.

Trial keys have lower limits than full keys: 2 concurrent requests and 60 requests per minute, against 8 concurrent and 300 per minute for a full key. If you test with a script that fires parallel calls, you may see HTTP 429 with the code concurrency or rate_limited. Slow the script down rather than assuming something is broken.

To start, sign in with Google or with an email and password, then press the claim button on the API key page. It is one trial per person, and the credit expires after 7 days even if you have not used it.

Subscription or pay as you go

Neither model is always cheaper. A flat monthly plan is predictable, and if you hit it hard every day it can beat per-token billing. Per-token billing wins when your use is uneven: a week of heavy work followed by a quiet month costs only what you used, and nothing is lost when you stop.

The way to decide is to measure. Take a normal week of work, log input and output tokens for each call, and apply the formula above. Then compare that number, multiplied for a month, with the plan price on the vendor's own page. If the per-token total is a fraction of the plan, pay as you go is the better fit. If it is close or higher, the plan may be the better deal.

One more difference matters as much as price. This is a hosted, OpenAI-compatible API with a single open-weight model tuned to answer without content refusals for lawful adult use. It is not the official API of any model vendor and it does not route between vendors. It is text only: no images, audio, video, embeddings or fine-tuning. If you need any of those, price them separately.

Ways to keep the bill small

  • Trim history. Send the last few turns plus a short summary rather than the whole conversation.
  • Set max_tokens when you know the answer is short. It is optional, but it caps runaway output, which is the pricier side.
  • Do not paste whole repositories. A 20,000-token prompt costs $0.003 on input alone. Send the files that matter.
  • Cache your own results. If the same prompt repeats, store the answer yourself.
  • Read the balance header. X-Balance-USD tells you what is left after each call.

Prompts are not used for training, which matters if you paste code or private text. For the exact setup, the quickstart in the docs shows how to point an existing OpenAI client at this API by changing the base URL and key. If you are weighing other providers, the page on Groq API myths and facts covers a related question about speed and refusals.

Questions and answers

Is there a free unlimited tier?

No. New users get a one-time $0.50 trial credit, valid for 7 days, claimed with one click on the API key page. After that you pay per token from prepaid credit.

How much does one request cost?

It depends on tokens. A request with 2,000 input and 500 output tokens costs $0.00055, using $0.15 per 1M input and $0.50 per 1M output.

Do failed requests cost anything?

No. Failed or refused requests are not charged, and your prepaid credit never expires.

What is the smallest top-up?

$20, in any whole amount up to $500. Bonuses of 5%, 10% and 15% apply from $50, $100 and $200.

Your key is one form away

Create an account, copy the key, change the base URL. That is the whole setup.

Get API key