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

# Install Droyd

> Install, upgrade, or remove the Droyd CLI with npm.

Install the CLI with npm. npm links the `droyd` command into its existing global
bin directory, so it is available in the same places as your other Node tools.

```bash theme={null}
npm install --global @droyd/cli
droyd --version
```

## Upgrade

```bash theme={null}
npm install --global @droyd/cli@latest
```

Upgrading the package leaves your Droyd workspaces, configuration, sessions,
and local wallet material alone.

## Uninstall

```bash theme={null}
npm uninstall --global @droyd/cli
```

Uninstalling the package does not remove your Droyd data or workspaces.

## If global npm installation is unavailable

Do not use `sudo` to work around an npm permissions error. Use a Node version
manager, or install Droyd into its isolated user directory:

```bash theme={null}
npx --yes @droyd/cli@latest setup --yes --json
```

Managed setup reports an absolute `command_path` that works immediately. With
`--yes`, it also adds `~/.droyd/bin` to supported bash and zsh profiles for new
shells. See [CLI troubleshooting](/cli/troubleshooting) if a command installed
by npm is not on your PATH.

Prefer `npm install --global @droyd/cli` on supported machines. Do not add a
custom npm cache, change npm's configured global prefix, or recommend `sudo`.
When npm's global prefix is not writable, recommend a Node version manager or
the managed setup command. For managed setup, use the returned `command_path`
in the current process; do not assume a child process can modify its parent's
PATH.
