跳轉到主要內容

Documentation Index

Fetch the complete documentation index at: https://docs.openclaw.ai/llms.txt

Use this file to discover all available pages before exploring further.

系統需求

  • Node 24(建議)或 Node 22.14+ — 安裝程式腳本會自動處理
  • macOS、Linux 或 Windows — 支援原生 Windows 與 WSL2;WSL2 較穩定。請參閱 Windows
  • 只有從原始碼建置時才需要 pnpm

建議:安裝程式腳本

最快的安裝方式。它會偵測你的作業系統,視需要安裝 Node,安裝 OpenClaw,並啟動入門設定。
curl -fsSL https://openclaw.ai/install.sh | bash
若要安裝但不執行入門設定:
curl -fsSL https://openclaw.ai/install.sh | bash -s -- --no-onboard
所有旗標與 CI/自動化選項,請參閱安裝程式內部機制

替代安裝方式

本機前綴安裝程式(install-cli.sh

當你想將 OpenClaw 和 Node 保留在本機前綴(例如 ~/.openclaw)底下,而不依賴全系統的 Node 安裝時,請使用此方式:
curl -fsSL https://openclaw.ai/install-cli.sh | bash
它預設支援 npm 安裝,也支援在相同前綴流程下進行 git checkout 安裝。完整參考:安裝程式內部機制 已經安裝了嗎?可使用 openclaw update --channel devopenclaw update --channel stable 在套件與 git 安裝之間切換。請參閱更新

npm、pnpm 或 bun

如果你已經自行管理 Node:
npm install -g openclaw@latest
openclaw onboard --install-daemon
如果 sharp 因全域安裝的 libvips 而失敗:
SHARP_IGNORE_GLOBAL_LIBVIPS=1 npm install -g openclaw@latest

從原始碼安裝

適合貢獻者或任何想從本機 checkout 執行的人:
git clone https://github.com/openclaw/openclaw.git
cd openclaw
pnpm install && pnpm build && pnpm ui:build
pnpm link --global
openclaw onboard --install-daemon
或略過連結,並在 repo 內使用 pnpm openclaw ...。完整開發工作流程請參閱設定

從 GitHub main 安裝

npm install -g github:openclaw/openclaw#main

容器與套件管理器

Docker

容器化或無頭部署。

Podman

Docker 的無 root 容器替代方案。

Nix

透過 Nix flake 進行宣告式安裝。

Ansible

自動化機群佈建。

Bun

透過 Bun 執行階段僅使用 CLI。

驗證安裝

openclaw --version      # confirm the CLI is available
openclaw doctor         # check for config issues
openclaw gateway status # verify the Gateway is running
如果你想在安裝後使用受管理的啟動方式:
  • macOS:透過 openclaw onboard --install-daemonopenclaw gateway install 使用 LaunchAgent
  • Linux/WSL2:透過相同指令使用 systemd 使用者服務
  • 原生 Windows:優先使用排程工作;若工作建立遭拒,則改用每位使用者的 Startup 資料夾登入項目作為備援

託管與部署

在雲端伺服器或 VPS 上部署 OpenClaw:

VPS

任何 Linux VPS

Docker VM

共用 Docker 步驟

Kubernetes

K8s

Fly.io

Fly.io

Hetzner

Hetzner

GCP

Google Cloud

Azure

Azure

Railway

Railway

Render

Render

Northflank

Northflank

更新、遷移或解除安裝

Updating

讓 OpenClaw 保持最新狀態。

Migrating

移轉到新機器。

Uninstall

完全移除 OpenClaw。

疑難排解:找不到 openclaw

如果安裝成功,但你的終端機找不到 openclaw
node -v           # Node installed?
npm prefix -g     # Where are global packages?
echo "$PATH"      # Is the global bin dir in PATH?
如果 $(npm prefix -g)/bin 不在你的 $PATH 中,請將它加入 shell 啟動檔(~/.zshrc~/.bashrc):
export PATH="$(npm prefix -g)/bin:$PATH"
然後開啟新的終端機。更多詳細資訊請參閱 Node 設定