# Koo CLI

The Koo CLI deploys your app from your terminal. Its flagship command, `koo up`, packs your working directory, uploads it, builds it, and rolls it out — following progress until your service is online, then printing its URL.

## Install

The CLI is a single self-contained binary for macOS, Linux, and Windows. Install it with your package manager of choice.

```bash
# Homebrew (6.0+ requires trusting third-party taps)
brew tap koo-io/koo
brew trust koo-io/koo
brew install koo
```

```bash
# npm
npm install -g @koo-io/cli
```

```bash
# Cargo
cargo install koo
```

Run `koo --version` to confirm the install.

## Log in

`koo login` opens your browser to authorize the CLI, then stores the session in your operating system's keyring — nothing is written to disk in plaintext. `koo whoami` prints who you're acting as, and `koo logout` clears the stored session.

```bash
koo login
koo whoami
```

> **Note:**
>
> For CI and other headless environments, skip the browser step: set `KOO_TOKEN` to a `kc_…` [API token](/docs/developers/api-tokens) and every command authenticates with it.

## Deploy with `koo up`

From your app's directory, run `koo up`. It packs the working tree — honoring `.gitignore`, `.kooignore`, and `.dockerignore` — uploads it, builds a container image, and ships it as a new [deployment](/docs/deploy/deployments-and-rollback). This section covers the essentials; [the `koo up` guide](/docs/deploy/koo-up) is the full walkthrough.

```bash
koo up
```

By default `koo up` waits: it shows the build's progress stage by stage, then follows the rollout until your service reports online, and prints its URL. The full build log isn't streamed to your terminal — when a build fails, the CLI prints the log's tail so you can see why. Pass `--detach` to return as soon as the deploy is queued.

The first time you run it in a directory, `koo up` asks which account, project, environment, and service to deploy into — picking or creating each — and records all four in a `koo.json` file. To set that up ahead of time, run `koo link` yourself.

```bash
koo link
```

This is the same from-source path as [Deploy from Git](/docs/deploy/deploy-from-git), driven from your machine instead of a repository. To ship a prebuilt image instead, see [Deploy a container](/docs/deploy/deploy-a-container).

## Watch your service

`koo status` shows the current health and live URL of the linked service. `koo logs` tails its [logs](/docs/observability/logs); add `-f` to follow.

```bash
koo status
koo logs -f
```

## Manage variables

Read and change a service's [variables](/docs/configuration/variables) without leaving the terminal.

```bash
koo variables list
koo variables set DEBUG=true
koo variables unset DEBUG
```

Run a command locally with the service's variables in scope — handy for running your app against its real configuration:

```bash
koo run -- npm run dev
```

Sensitive values — database URLs, passwords — are withheld: the CLI skips them with a notice naming each one. When a command needs one, reveal it in the console.

## Command reference

## Related

- 
-
