> ## Documentation Index
> Fetch the complete documentation index at: https://developer.upsun.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Install the Upsun CLI

> Install the Upsun CLI on macOS, Linux, or Windows to manage your projects from the terminal. Includes authentication, updates, and legacy CLI upgrade steps.

## Install

<Tabs>
  <Tab title="macOS (Homebrew)">
    Trust the Upsun tap, then install:

    ```bash theme={null}
      brew install upsun/tap/upsun-cli
    ```
  </Tab>

  <Tab title="Linux">
    ```bash theme={null}
      curl -fsSL https://raw.githubusercontent.com/upsun/cli/main/installer.sh | bash
    ```
  </Tab>

  <Tab title="Windows (Scoop)">
    Install the [Scoop Extras bucket](https://github.com/ScoopInstaller/Extras) before proceeding:

    ```bash theme={null}
      scoop bucket add extras
    ```

    Then add the Upsun bucket and install the CLI:

    ```bash theme={null}
      scoop bucket add upsun https://github.com/upsun/homebrew-tap.git
      scoop install upsun
    ```
  </Tab>
</Tabs>

To verify the installation, run:

```bash theme={null}
upsun --version
```

## Authenticate

Run the following command to authenticate and to manage your projects:

```bash theme={null}
upsun
```

This command opens a browser tab for you to log in.
It also creates certificates on your computer for [SSH](/docs/development/ssh).

After logging in, you see a list of your projects and tips for getting started.
If you experience authentication issues or want to force a login, run `upsun login`.

To install and authenticate the CLI in a CI system or app container using a build hook, see [Authenticate using an API token](/cli/api-tokens).

## Update the CLI

To update the CLI, run the appropriate command for your platform:

<Tabs>
  <Tab title="Homebrew">
    ```bash theme={null}
      brew upgrade upsun-cli
    ```
  </Tab>

  <Tab title="Linux">
    ```bash theme={null}
      curl -fsSL https://raw.githubusercontent.com/upsun/cli/main/installer.sh | bash
    ```
  </Tab>

  <Tab title="Scoop">
    ```bash theme={null}
      scoop update upsun
    ```
  </Tab>
</Tabs>

## Upgrade from the legacy CLI

Follow the [installation instructions above](#install).
Once installed, the CLI guides you through removing the legacy CLI.
