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

# Installation

> Install the sqd CLI in your local environment — npm install -g, standalone binaries for macOS/Linux/Windows, and shell autocomplete configuration.

Squid CLI is a command line tool for

* scaffolding new squids from templates
* running SDK tools and scripts defined in `commands.json` in a cross-platform way
* managing squid deployments in [SQD Cloud](/en/cloud) (former Aquarium)

The CLI is distributed as a [`npm` package](https://www.npmjs.com/package/@subsquid/cli).

To install Squid CLI, follow the steps below.

<Steps>
  <Step title="0. Install and setup Squid CLI">
    First, install the latest version of Squid CLI as a global `npm` package:

    ```bash theme={"system"}
    npm i -g @subsquid/cli@latest
    ```

    Check the version:

    ```bash theme={"system"}
    sqd --version
    ```

    Make sure the output looks like `@subsquid/cli@<version>`.

    <Info>
      The next steps are **optional** for building and running squids. A key is required to enable the CLI commands managing the [SQD Cloud](/en/cloud) deployments.
    </Info>
  </Step>

  <Step title="1. Obtain a SQD Cloud deployment key">
    Sign in to [Cloud](https://app.subsquid.io/), and obtain (or refresh) the deployment key page by clicking at the profile picture > "Deployment key":

    <Frame>
      <img src="https://mintcdn.com/sqd-2119b3c3/awHMqZ4SD9pCrHZk/en/sdk/squid-sdk/squid-cli/installation-deployment-key.png?fit=max&auto=format&n=awHMqZ4SD9pCrHZk&q=85&s=af0e99de2cc5bf172f60d7b2230ff55e" alt="SQD Cloud deployment key page" width="794" height="133" data-path="en/sdk/squid-sdk/squid-cli/installation-deployment-key.png" />
    </Frame>
  </Step>

  <Step title="2. Authenticate Squid CLI">
    Open a terminal window and run

    ```bash theme={"system"}
    sqd auth -k <DEPLOYMENT_KEY>
    ```
  </Step>

  <Step title="3. Explore with `--help`">
    Use `sqd --help` to get a list of the available command and `sqd <command> --help` to get help on the available options for a specific command, e.g.

    ```bash theme={"system"}
    sqd deploy --help
    ```
  </Step>
</Steps>
