OpenClawSkills
GitHub
CLI Reference β€’ TutorialHeader.readTime

Update

CLI reference for openclaw update (secure sources + gateway auto-restart).

Safely update OpenClaw and switch between stable/beta/dev channels.

If you installed via ''npm/pnpm'' (global install, no git metadata), updates happen via the package manager flow in ''Updating''.

Tutorial.step

Usage

Bash
openclaw update
openclaw update status
openclaw update wizard
openclaw update --channel beta
openclaw update --channel dev
openclaw update --tag beta
openclaw update --no-restart
openclaw update --json
openclaw --update
Tutorial.step

Options

- ''--no-restart'': Skip restarting gateway service after successful update.

- ''--channel <stable|beta|dev>'': Set update channel (git + npm; persisted in config).

- ''--tag <dist-tag|version>'': Override npm dist-tag or version for this update only.

- ''--json'': Print machine-readable ''UpdateRunResult'' JSON.

- ''--timeout <seconds>'': Timeout per step (default 1200s).

Note: Downgrades require confirmation because older versions may break config.

Tutorial.step

`update status`

Show active update channel + git tag/branch/SHA (for source checkout) and update availability.

Bash
openclaw update status
openclaw update status --json
openclaw update status --timeout 10

Options:

- ''--json'': Print machine-readable status JSON.

- ''--timeout <seconds>'': Check timeout (default 3s).

Tutorial.step

`update wizard`

Interactive flow to select update channel and confirm whether to restart gateway

after update (default is to restart). If you select ''dev'' without a git checkout, it

proposes to create one.

Tutorial.step

What it does

When you explicitly switch channels (''--channel ...''), OpenClaw also keeps

install method aligned:

- ''dev'' β†’ ensures git checkout (default: ''~/openclaw'', override with ''OPENCLAW_GIT_DIR''),

updates it, and installs global CLI from that checkout.

- ''stable''/''beta'' β†’ install from npm using matching dist-tag.

Tutorial.step

Git checkout flow

Channels:

- ''stable'': check out latest non-beta tag, then build + doctor.

- ''beta'': check out latest ''-beta'' tag, then build + doctor.

- ''dev'': check out ''main'', then fetch + rebase.

High level:

1. Requires a clean working tree (no uncommitted changes).

2. Switch to selected channel (tag or branch).

3. Fetch upstream (dev only).

4. Dev only: pre-check lint + TypeScript build in temporary worktree; if prompt fails, back up to 10 commits to find latest clean build.

5. Rebase to selected commit (dev only).

6. Install deps (pnpm preferred; npm fallback).

7. Build + build control UI.

8. Run ''openclaw doctor'' as final "safe update" check.

9. Sync plugins to active channel (dev uses bundled extensions; stable/beta use npm) and update npm-installed plugins.

Tutorial.step

`--update` shorthand

''openclaw --update'' rewrites to ''openclaw update'' (useful for shell and launcher scripts).

Tutorial.step

See also

- ''openclaw doctor'' (offered to run first on git checkouts)

- ''Development Channels''

- ''Updating''

- ''CLI Reference''