Kimi K2.7 Code
MoonshotAI: Kimi K2.7 Code is a coding-focused model in Moonshot AI's Kimi K2 family, built to complete end-to-end programming tasks reliably over long contexts.
kimi-k2.7-codeReleased 12 Jun 2026 (Jun 2026)Pricing
List prices at Moonshot AI, in US dollars per million tokens.
| Tier | Input / 1M | Output / 1M | |
|---|---|---|---|
| Standard | $0.95 | $4.00 | |
| Cached input 80% off input | $0.19 | 80% off input |
What it costs a month
At Moonshot AI list prices, 30 days.
- Chat assistant5,000 requests a day, 2K in / 0.5K out, cached$517
- RAG over documents2,000 requests a day, 8K in / 0.6K out, cached$418
- Coding agent1,000 requests a day, 40K in / 2K out, cached$742
- Overnight batch20,000 requests a day, 4K in / 0.4K out$3,240
Where to run it
23 hosts serve Kimi K2.7 Code. The comparison is on blended price, 3 parts input to 1 part output.
| Host | In / out per 1M | Model id | |
|---|---|---|---|
Moonshot AILab API kimi-k2.7-code | $0.95 / $4.00 | kimi-k2.7-code | |
CLF AI GatewayCloud kimi-k2.7-code | $0.38 / $1.60 −60% vs headline | kimi-k2.7-code | |
W&B InferenceInference Kimi-K2.7-Code | $0.60 / $3.00 −30% vs headline | Kimi-K2.7-Code | |
DeepInfraInference Kimi-K2.7-Code | $0.68 / $3.40 −21% vs headline | Kimi-K2.7-Code | |
ai&Cloud kimi-k2.7-code | $0.75 / $3.50 −16% vs headline | kimi-k2.7-code | |
Alibaba DashScopeLab API kimi-k2.7-code | $0.95 / $4.00 | kimi-k2.7-code | |
Qianwen AI PlatformLab API kimi-k2.7-code | $0.95 / $4.00 | kimi-k2.7-code | |
Qwen CloudLab API kimi-k2.7-code | $0.95 / $4.00 | kimi-k2.7-code | |
EmpirioLabs AICloud kimi-k2-7-code | $0.95 / $4.00 | kimi-k2-7-code | |
Azure AI FoundryCloud kimi-k2.7-code | $0.95 / $4.00 Retires 16 Apr 2027 | kimi-k2.7-code | Retires 16 Apr 2027 |
kimi-k2.7-code | $0.95 / $4.00 | kimi-k2.7-code | |
OpenCode GoCloud kimi-k2.7-code | $0.95 / $4.00 | kimi-k2.7-code | |
StreamLakeCloud kimi-k2.7-code | $0.95 / $4.00 | kimi-k2.7-code | |
Tencent TokenHubCloud kimi-k2.7-code | $0.95 / $4.00 | kimi-k2.7-code | |
BasetenInference Kimi-K2.7-Code | $0.95 / $4.00 | Kimi-K2.7-Code | |
Nebius AI StudioInference Kimi-K2.7-Code | $0.95 / $4.00 | Kimi-K2.7-Code | |
Together AIInference Kimi-K2.7-Code | $0.95 / $4.00 | Kimi-K2.7-Code | |
GMI CloudInference kimi-k2.7-code | $0.95 / $4.00 | kimi-k2.7-code | |
Novita AIInference kimi-k2.7-code | $0.95 / $4.00 | kimi-k2.7-code | |
Fireworks AIInference kimi-k2p7-code | $0.95 / $4.00 | kimi-k2p7-code | |
PerplexityGateway kimi-k2.7-code | $0.95 / $4.00 | kimi-k2.7-code | |
Inference APIsGateway Kimi-K2.7-Code | $0.89 / $4.42 +4% vs headline | Kimi-K2.7-Code | |
Kyma APICloud kimi-k2.7-code | $1.01 / $4.77 +14% vs headline | kimi-k2.7-code |
Show 2 more listings: regions, snapshots and variantsHide regional listings
| Fireworks AI | |||||||
| Alias kimi-k2p7-code | $0.95 / $4.00 | kimi-k2p7-code | |||||
| Inference APIs | |||||||
| Alias kimi-k2.7-code | $0.89 / $4.42 +4% vs headline | kimi-k2.7-code | |||||
Capabilities
Core
- Streaming
- Function calling
- JSON mode
- Structured outputs
Multimodal
- Vision
- Image input
- Audio
- Image generation
- Video
Advanced
- Reasoning
- Tool calling
- MCP
- Prompt caching
- Batch API
- Embeddings
- Takes in
- TextImagesVideo
- Produces
- Text
- Features
- Prompt cachingVideo input
- Open weights
- License: Modified MIT LicenseRuns in about 2464.5 GB of GPU memoryRuntimes: SGLang, vLLM
Cheaper alternatives
Current models that cost less and keep most of what this one can do: tools, vision, reasoning, structured output, caching and enough context.
Same model, cheaper host
- CLF AI Gateway60% lesskimi-k2.7-code$0.38 / $1.60
- W&B Inference30% lessKimi-K2.7-Code$0.60 / $3.00
- DeepInfra21% lessKimi-K2.7-Code$0.68 / $3.40
- ai&16% lesskimi-k2.7-code$0.75 / $3.50
Smaller Moonshot AI models
No cheaper Moonshot AI model keeps its key capabilities.
Other frontier labs
- 1% less
- 12% less
- 27% less
- 88% less
Open-weight picks
- 63% less
- 69% less
- 72% less
- 75% less
Call it
Using Moonshot AI's API.
from litellm import completion
response = completion(
model="moonshot/kimi-k2.7-code",
messages=[{"role": "user", "content": "Hello"}],
)
print(response.choices[0].message.content)Quick answers
How much does Kimi K2.7 Code cost?
On Moonshot AI, Kimi K2.7 Code costs $0.95 per million input tokens and $4.00 per million output tokens. Cached input costs $0.19 per million tokens. The cheapest host is CLF AI Gateway, at $0.38 per million input tokens and $1.60 per million output tokens.
Which APIs offer Kimi K2.7 Code?
Kimi K2.7 Code runs on 23 APIs: Moonshot AI, CLF AI Gateway, W&B Inference, DeepInfra, ai&, Alibaba DashScope, Qianwen AI Platform, Qwen Cloud, EmpirioLabs AI and 14 more.
What is Kimi K2.7 Code's context window?
262K tokens, with up to 262K tokens in one reply.
Is Kimi K2.7 Code being retired?
Azure AI Foundry retires it on 16 Apr 2027. 22 hosts keep serving it.
What are cheaper alternatives to Kimi K2.7 Code?
Models that cost less and keep most of what it can do: GPT-5.4 Mini on OpenAI (1% less), Gemini 3.8 Flash on Google AI Studio (12% less) and Inkling Small on DeepInfra (63% less). Kimi K2.7 Code itself costs 60% less on CLF AI Gateway. Savings are on a mix of 3 input tokens to 1 output token.
When was Kimi K2.7 Code released?
Moonshot AI released it on 12 Jun 2026.
What is Kimi K2.7 Code's API model id?
Use kimi-k2.7-code with Moonshot AI. Other hosts use their own ids: Kimi-K2.7-Code on W&B Inference, Kimi-K2.7-Code on DeepInfra, kimi-k2-7-code on EmpirioLabs AI, Kimi-K2.7-Code on Baseten.
Sources
- Baseten pricing
- DeepInfra pricing
- Inference APIs pricing
- Nebius AI Studio pricing
- Together AI pricing
- W&B Inference pricing
- EmpirioLabs AI pricing
- ai& pricing
- Azure AI Foundry pricing
- CLF AI Gateway pricing
- Alibaba DashScope pricing
- GMI Cloud pricing
- Moonshot AI pricing
- Novita AI pricing
- OpenCode Go pricing
- Perplexity pricing
- Qianwen AI Platform pricing
- Qwen Cloud pricing
- StreamLake pricing
- Tencent TokenHub pricing
- Fireworks AI pricing
- LiteLLM model map
Raw catalog entry for kimi-k2.7-code on Moonshot AI
{
"cache_read_input_token_cost": 1.9e-7,
"input_cost_per_token": 9.5e-7,
"litellm_provider": "moonshot",
"max_input_tokens": 262144,
"max_output_tokens": 262144,
"mode": "chat",
"output_cost_per_token": 0.000004,
"source": "https://platform.kimi.ai/docs/pricing/chat-k27-code",
"supports_function_calling": true,
"supports_prompt_caching": true,
"supports_reasoning": true,
"supports_response_schema": true,
"supports_tool_choice": true,
"supports_video_input": true,
"supports_vision": true
}