Kimi Code reads and edits code, runs shell commands and decides for itself what to do next. It is Moonshot AI's terminal agent: one command installs it on macOS, Linux and Windows, and the CLI itself is open on GitHub under the MIT license. Below you will find the install, the two ways to sign in (a subscription or an API key) and how it differs from Claude Code.
What Kimi Code is
The project describes itself as "AI coding agent that runs in your terminal" (GitHub). It runs on Moonshot AI models, mainly Kimi K2.7 Code and Kimi K3 (the K3 model itself is covered in Kimi K3: review). According to the repository description, models from other providers work too.
On the technical side: a single-file install with no Node.js dependency, a fast start through the TUI (a text interface right in the terminal) and built-in support for the Model Context Protocol. A technical review on marktechpost.com reports that the project is written in TypeScript, while its predecessor was called kimi-cli and was written in Python. Secondary sources say version 0.4.0 was the full move to the new stack (biggo.com). Still, check the current version number in the repository itself: the tool changes fast.
Installing Kimi Code
macOS and Linux
curl -fsSL https://code.kimi.com/kimi-code/install.sh | bash
Windows (PowerShell)
irm https://code.kimi.com/kimi-code/install.ps1 | iex
Both commands come from the official repository, github.com/MoonshotAI/kimi-code, and were correct on the date we checked. If the script fails, open the Installation section of the repository README: it lists other ways to install, including for systems without curl or PowerShell.
How to sign in: subscription or API key
There are two ways into Kimi Code. The first, Kimi Code OAuth, is tied to a paid Kimi subscription (the Plus, Pro, Max and Ultra plans, formerly Moderato, Allegretto, Allegro and Vivace) and spends the account's shared credit pool. On the new plans the Kimi Code limit is a rolling 5-hour window with no weekly limit. The legacy plans keep both. When the monthly credit pool runs out, Kimi Code stops working too (Kimi help).
The second way, according to the marktechpost.com review, is an API key from the Moonshot AI Open Platform. Here you pay for tokens at the usual API prices instead of paying for a subscription: cache hit, cache miss and output are priced separately for each model. Current figures and subscription plans are collected in Kimi subscription and payment from Russia.
There is no separate price list for Kimi Code as a product. It is either included in the subscription or billed as an ordinary model call through the API.
Kimi Code, Codex CLI and Claude Code: what differs
All three do one job: an agent in the terminal that writes and edits code. They differ in whose models stand behind it and how you pay for them.
Kimi Code runs on Kimi models from Moonshot AI, and you sign in with a subscription or a Moonshot key. Codex CLI from OpenAI runs on GPT models, with the same choice between a ChatGPT subscription and an API key. Claude Code from Anthropic runs on Claude models; you can sign in through an Anthropic account or with any compatible API key, third-party gateways included. For a closer look at Codex, Cursor and Claude Code as tools, see Codex CLI vs Cursor vs Claude Code; there is no point retelling it all here.
For a reader in Russia the practical difference is this. A Kimi subscription and a Codex subscription are tied to the vendor's account and its payment methods. In Claude Code you can put the key of a compatible gateway in place of an Anthropic account, and then neither Anthropic's regional restrictions nor a VPN get in the way.
Claude Code through codexkey: the same format, access from Russia
Claude Code takes its address and key from environment variables. Point them at codexkey and the agent stays in the familiar terminal format but runs on Claude Opus 5 and Claude Sonnet 5. You pay in rubles and do not need to sign in to an Anthropic account:
export ANTHROPIC_BASE_URL="https://api.codexkey.online"
export ANTHROPIC_AUTH_TOKEN="sk_cdx_YOUR_KEY"
export ANTHROPIC_DEFAULT_OPUS_MODEL="claude-opus-5-5[1m]"
export ANTHROPIC_DEFAULT_SONNET_MODEL="claude-sonnet-5[1m]"
export ANTHROPIC_DEFAULT_HAIKU_MODEL="claude-sonnet-5"
claude
The ANTHROPIC_DEFAULT_* lines are required. Without them Claude Code asks for its own default models and answers "There's an issue with the selected model".
Step-by-step setup for Linux, macOS and Windows, including a permanent config in ~/.claude/settings.json, is in the Claude Code guide. A caveat: this is not a replacement for Kimi Code but a second route for people who want Claude itself in the terminal and want to pay with a Russian card or through SBP (the Russian Faster Payments System). codexkey also carries Kimi models (kimi-k3, kimi-k3.1-pro, kimi-k2.7-code), and in Claude Code you pick them with the /model command. But Kimi Code itself and a Kimi subscription are not sold through codexkey.
FAQ
Is Kimi Code free?
The CLI itself is free and open on GitHub under the MIT license. To use Kimi models through it, though, you need a paid Kimi subscription or a funded balance on the Moonshot API platform. The API has no free tier, and the minimum top-up is $1.
Do I need a Kimi subscription to use Kimi Code?
No. You can sign in with a Moonshot AI Open Platform API key and pay for the tokens you use, with no Plus, Pro, Max or Ultra subscription.
How does Kimi Code differ from Claude Code?
Kimi Code runs on Moonshot AI models and needs a Moonshot account or API key. Claude Code runs on Claude models and accepts third-party compatible endpoints, codexkey included, so no Anthropic account is needed.
Does Kimi Code work in Russia?
We found no official statement in the Kimi Code or Moonshot AI documentation that Russian IPs are blocked. Paying with a Russian card is a separate question and has no official solution: see Kimi subscription and payment from Russia.
Can I use a model other than Kimi through Kimi Code?
According to the repository description the tool is meant to work with other model providers, but its main scenario and all of its presentation are built around Kimi models. For agentic coding on Claude, use Claude Code directly: it was built for the Anthropic ecosystem and MCP from the start.
Which Kimi Code version is current?
The project changes quickly and the version number goes stale. Check the latest release tag in the github.com/MoonshotAI/kimi-code repository. The install script pulls the newest build every time.