How to Install Kimi CLI on Linux: A Complete Guide Using uv

The fastest way to install Kimi CLI on Linux is to run the official one-line installer that bootstraps the uv package manager and installs the tool for Python 3.13.

Kimi CLI (also referred to as Kimi Code CLI) is MoonshotAI's command-line interface for interacting with Kimi AI models. According to the MoonshotAI/kimi-cli source code, the application is distributed as a Python uv tool, which provides a fast, reproducible installation path on Linux systems.

Method 1: Install Kimi CLI Using the Official One-Liner

The recommended approach for most Linux users is the automated installer script hosted at code.kimi.com. This script handles all dependencies and configures the environment automatically.

Run the following command in your terminal:

curl -LsSf https://code.kimi.com/install.sh | bash

How the Installer Works

The installation logic resides in [scripts/install.sh](https://github.com/MoonshotAI/kimi-cli/blob/main/scripts/install.sh) and performs three key operations:

  1. Detects your download tool – The script checks for curl or wget availability (lines 5-12) to fetch the uv installer.
  2. Bootstraps uv – If uv is not already present on your PATH, the script installs it; otherwise, it reuses the existing installation (lines 19-24).
  3. Installs the package – Finally, the script executes uv tool install --python 3.13 kimi-cli to install the CLI targeting Python 3.13 (line 31).

Method 2: Manual Installation with uv

If you already have uv installed on your Linux system, you can skip the script and install Kimi CLI directly:

uv tool install --python 3.13 kimi-cli

This command is identical to the one invoked by the automated installer and creates the kimi executable in your uv tools directory.

Verify Your Installation

After installation completes, confirm that the kimi command is available on your system PATH:

kimi --version

The uv tool manager generates this executable automatically during the installation process.

Managing Your Kimi CLI Installation

Once installed, you can maintain the tool using uv's built-in commands.

Upgrading Kimi CLI

To update to the latest release while bypassing the cache:

uv tool upgrade kimi-cli --no-cache

This command is documented in the Getting Started guide (lines 66-75).

Uninstalling Kimi CLI

To remove the tool from your system:

uv tool uninstall kimi-cli

First Run and Configuration

After you install Kimi CLI on Linux, navigate to your project directory and invoke the tool:

kimi

On first launch, the CLI prompts you to configure an LLM provider using the /login slash command. The complete first-run workflow is detailed in [docs/en/guides/getting-started.md](https://github.com/MoonshotAI/kimi-cli/blob/main/docs/en/guides/getting-started.md) (lines 77-92).

Summary

Frequently Asked Questions

Do I need Python installed before running the Kimi CLI installer?

No. The installer script automatically handles Python 3.13 via uv. The [scripts/install.sh](https://github.com/MoonshotAI/kimi-cli/blob/main/scripts/install.sh) explicitly targets Python 3.13 when invoking the installation command, so you do not need a pre-existing Python environment on your Linux system.

Can I install Kimi CLI on Linux without using the one-line script?

Yes. If you prefer not to run the automated script, you can manually install uv first, then execute uv tool install --python 3.13 kimi-cli. This approach gives you full control over the uv installation process while achieving the same end result.

How do I update Kimi CLI to the latest version?

Run uv tool upgrade kimi-cli --no-cache to fetch and install the latest release. The --no-cache flag ensures you bypass any stale package indexes and receive the most recent version available in the repository.

Where does the installation script place the Kimi CLI executable?

The kimi binary is managed by uv and placed in uv's tool directory, which is automatically added to your shell's PATH during the installation process. You can verify the location by running which kimi after installation completes.

Have a question about this repo?

These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:

Share the following with your agent to get started:
curl -s "https://instagit.com/install.md"

Works with
Claude Codex Cursor VS Code OpenClaw Any MCP Client

Maintain an open-source project? Get it listed too →