2026-01-12 01:08:00 +00:00
---
2026-02-06 08:55:05 -05:00
summary: "Install OpenClaw — installer script, npm/pnpm, from source, Docker, and more"
2026-01-12 01:08:00 +00:00
read_when:
2026-02-06 08:55:05 -05:00
- You need an install method other than the Getting Started quickstart
- You want to deploy to a cloud platform
- You need to update, migrate, or uninstall
title: "Install"
2026-01-12 01:08:00 +00:00
---
2026-02-06 08:55:05 -05:00
# Install
2026-01-12 01:08:00 +00:00
2026-02-06 08:55:05 -05:00
Already followed [Getting Started ](/start/getting-started )? You're all set — this page is for alternative install methods, platform-specific instructions, and maintenance.
2026-01-16 23:18:44 +00:00
2026-01-20 07:42:21 +00:00
## System requirements
2026-01-16 23:10:10 +00:00
2026-02-06 08:55:05 -05:00
- **[Node 22+ ](/install/node )** (the [installer script ](#install-methods ) will install it if missing)
- macOS, Linux, or Windows
2026-01-20 07:42:21 +00:00
- `pnpm` only if you build from source
2026-02-06 08:55:05 -05:00
<Note>
On Windows, we strongly recommend running OpenClaw under [WSL2 ](https://learn.microsoft.com/en-us/windows/wsl/install ).
</Note>
## Install methods
<Tip>
The **installer script ** is the recommended way to install OpenClaw. It handles Node detection, installation, and onboarding in one step.
</Tip>
2026-02-19 08:30:24 +01:00
<Warning>
For VPS/cloud hosts, avoid third-party "1-click" marketplace images when possible. Prefer a clean base OS image (for example Ubuntu LTS), then install OpenClaw yourself with the installer script.
</Warning>
2026-02-06 08:55:05 -05:00
<AccordionGroup>
<Accordion title="Installer script" icon="rocket" defaultOpen>
Downloads the CLI, installs it globally via npm, and launches the onboarding wizard.
<Tabs>
<Tab title="macOS / Linux / WSL2">
```bash
curl -fsSL https://openclaw.ai/install.sh | bash
` ``
</Tab>
<Tab title="Windows (PowerShell)">
` ``powershell
iwr -useb https://openclaw.ai/install.ps1 | iex
` ``
</Tab>
</Tabs>
That's it — the script handles Node detection, installation, and onboarding.
To skip onboarding and just install the binary:
<Tabs>
<Tab title="macOS / Linux / WSL2">
` ``bash
curl -fsSL https://openclaw.ai/install.sh | bash -s -- --no-onboard
` ``
</Tab>
<Tab title="Windows (PowerShell)">
` ``powershell
& ([scriptblock]::Create((iwr -useb https://openclaw.ai/install.ps1))) -NoOnboard
` ``
</Tab>
</Tabs>
For all flags, env vars, and CI/automation options, see [Installer internals](/install/installer).
</Accordion>
<Accordion title="npm / pnpm" icon="package">
If you already have Node 22+ and prefer to manage the install yourself:
<Tabs>
<Tab title="npm">
` ``bash
npm install -g openclaw@latest
openclaw onboard --install-daemon
` ``
<Accordion title="sharp build errors?">
If you have libvips installed globally (common on macOS via Homebrew) and ` sharp` fails, force prebuilt binaries:
` ``bash
SHARP_IGNORE_GLOBAL_LIBVIPS=1 npm install -g openclaw@latest
` ``
If you see ` sharp: Please add node-gyp to your dependencies`, either install build tooling (macOS: Xcode CLT + ` npm install -g node-gyp`) or use the env var above.
</Accordion>
</Tab>
<Tab title="pnpm">
` ``bash
pnpm add -g openclaw@latest
pnpm approve-builds -g # approve openclaw, node-llama-cpp, sharp, etc.
openclaw onboard --install-daemon
` ``
<Note>
pnpm requires explicit approval for packages with build scripts. After the first install shows the "Ignored build scripts" warning, run ` pnpm approve-builds -g` and select the listed packages.
</Note>
</Tab>
</Tabs>
</Accordion>
<Accordion title="From source" icon="github">
For contributors or anyone who wants to run from a local checkout.
<Steps>
<Step title="Clone and build">
Clone the [OpenClaw repo](https://github.com/openclaw/openclaw) and build:
` ``bash
git clone https://github.com/openclaw/openclaw.git
cd openclaw
pnpm install
pnpm ui:build
pnpm build
` ``
</Step>
<Step title="Link the CLI">
Make the ` openclaw` command available globally:
` ``bash
pnpm link --global
` ``
Alternatively, skip the link and run commands via ` pnpm openclaw ...` from inside the repo.
</Step>
<Step title="Run onboarding">
` ``bash
openclaw onboard --install-daemon
` ``
</Step>
</Steps>
For deeper development workflows, see [Setup](/start/setup).
</Accordion>
</AccordionGroup>
## Other install methods
<CardGroup cols={2}>
<Card title="Docker" href="/install/docker" icon="container">
Containerized or headless deployments.
</Card>
2026-02-14 17:39:06 +01:00
<Card title="Podman" href="/install/podman" icon="container">
Rootless container: run ` setup-podman.sh` once, then the launch script.
</Card>
2026-02-06 08:55:05 -05:00
<Card title="Nix" href="/install/nix" icon="snowflake">
Declarative install via Nix.
</Card>
<Card title="Ansible" href="/install/ansible" icon="server">
Automated fleet provisioning.
</Card>
<Card title="Bun" href="/install/bun" icon="zap">
CLI-only usage via the Bun runtime.
</Card>
</CardGroup>
2026-01-20 07:42:21 +00:00
## After install
2026-02-06 08:55:05 -05:00
Verify everything is working:
2026-01-12 01:08:00 +00:00
` ``bash
2026-02-06 08:55:05 -05:00
openclaw doctor # check for config issues
openclaw status # gateway status
openclaw dashboard # open the browser UI
2026-01-12 01:08:00 +00:00
` ``
2026-02-08 16:20:13 -05:00
If you need custom runtime paths, use:
- ` OPENCLAW_HOME` for home-directory based internal paths
- ` OPENCLAW_STATE_DIR` for mutable state location
- ` OPENCLAW_CONFIG_PATH` for config file location
See [Environment vars](/help/environment) for precedence and full details.
2026-02-06 08:55:05 -05:00
## Troubleshooting: ` openclaw` not found
2026-01-12 01:08:00 +00:00
2026-02-06 08:55:05 -05:00
<Accordion title="PATH diagnosis and fix">
Quick diagnosis:
2026-01-12 01:08:00 +00:00
` ``bash
2026-01-20 07:42:21 +00:00
node -v
npm -v
2026-01-22 04:26:18 +00:00
npm prefix -g
2026-01-20 07:42:21 +00:00
echo "$PATH"
2026-01-12 01:08:00 +00:00
` ``
2026-02-06 08:55:05 -05:00
If ` $(npm prefix -g)/bin` (macOS/Linux) or ` $(npm prefix -g)` (Windows) is **not** in your ` $PATH`, your shell can't find global npm binaries (including ` openclaw`).
2026-01-12 04:24:46 +00:00
2026-02-06 08:55:05 -05:00
Fix — add it to your shell startup file (` ~/.zshrc` or ` ~/.bashrc`):
2026-01-12 01:08:00 +00:00
` ``bash
2026-01-22 04:26:18 +00:00
export PATH="$(npm prefix -g)/bin:$PATH"
2026-01-12 01:08:00 +00:00
` ``
2026-01-22 04:26:18 +00:00
On Windows, add the output of ` npm prefix -g` to your PATH.
2026-01-20 07:42:21 +00:00
Then open a new terminal (or ` rehash` in zsh / ` hash -r` in bash).
2026-02-06 08:55:05 -05:00
</Accordion>
2026-01-12 01:08:00 +00:00
2026-01-20 07:42:21 +00:00
## Update / uninstall
2026-02-06 08:55:05 -05:00
<CardGroup cols={3}>
<Card title="Updating" href="/install/updating" icon="refresh-cw">
Keep OpenClaw up to date.
</Card>
<Card title="Migrating" href="/install/migrating" icon="arrow-right">
Move to a new machine.
</Card>
<Card title="Uninstall" href="/install/uninstall" icon="trash-2">
Remove OpenClaw completely.
</Card>
</CardGroup>