Skip to main content
Watch: I Built an AI App Without Leaving Databricks

Setup guide - Documented by Kilo Code

Use Kimi in Kilo Code

Kilo Code documents a built-in Moonshot provider. In VS Code you add it from Settings > Providers; in the CLI you set MOONSHOT_API_KEY and configure the moonshotai provider in kilo.json. Kimi model ids get a Kimi-tuned system prompt automatically.

Last verified 4 steps4 official sources

Steps

  1. Step 1.

    VS Code: open Settings (gear icon), go to the Providers tab, add Moonshot.ai and enter your API key. The extension stores this in your kilo.json config file.

  2. Step 2.

    CLI: set the API key as an environment variable.

    Terminal
    export MOONSHOT_API_KEY="your-api-key"
  3. Step 3.

    Or configure it in ~/.config/kilo/kilo.json or ./kilo.json.

    JSON
    {
      "provider": {
        "moonshotai": {
          "env": ["MOONSHOT_API_KEY"],
        },
      },
    }
  4. Step 4.

    Then set your default model. Kilo's docs example uses moonshotai/moonshot-v1-auto, which is discontinued; use the current Kimi K3 id instead.

    JSON
    {
      "model": "moonshotai/kimi-k3",
    }

Caveats

  • Kilo's docs example model moonshotai/moonshot-v1-auto was discontinued on August 31, 2026. moonshotai/kimi-k3 combines Kilo's documented provider/model format with the kimi-k3 entry in the moonshotai provider of the models.dev registry (sst/models.dev). Moonshot's model list confirms kimi-k3 as the current id.
  • Kilo's page still describes K2-Thinking and 200K context and links platform.moonshot.cn. Moonshot's docs say platform.kimi.ai keys only work with https://api.moonshot.ai/v1; the base URL above comes from the models.dev moonshotai provider.
  • Kilo automatically uses a Kimi-tuned system prompt for model IDs containing kimi.

FAQ

How do I use Kimi in Kilo Code?

Kilo Code documents a built-in Moonshot provider. In VS Code you add it from Settings > Providers; in the CLI you set MOONSHOT_API_KEY and configure the moonshotai provider in kilo.json. Kimi model ids get a Kimi-tuned system prompt automatically.

Which Kimi model ids work in Kilo Code?

The official docs read for this guide list moonshotai/kimi-k3, moonshotai/kimi-k2.7-code and moonshotai/kimi-k2.6. Requests go to https://api.moonshot.ai/v1.

Is this an official Kimi and Kilo Code setup?

Kilo Code documents this setup in its own docs. It was last checked against 4 official pages on October 17, 2026.

Sources

Last verified against 4 official pages.

Newsletter

New models, set up the day they ship

One email per week. New model releases, the coding tools that support them and how to wire them up.