{
  "$type": "site.standard.document",
  "bskyPostRef": {
    "cid": "bafyreiboukdfppka3s5gtwxilyerdanvppeflpag4i7mzksxur7qjpyrbm",
    "uri": "at://did:plc:ws6dhxzqnqxu5aqxt4kd27oc/app.bsky.feed.post/3mhfkkaivwsv2"
  },
  "coverImage": {
    "$type": "blob",
    "ref": {
      "$link": "bafkreigjzye3tavjemo7te7zkqdcb22o7tli4aegjpfilm2dqyie3aa6pm"
    },
    "mimeType": "image/jpeg",
    "size": 216824
  },
  "description": "The right update command depends on whether you used npm, git, or Docker to install OpenClaw.",
  "path": "/how-to-update-openclaw-every-install-method-covered/",
  "publishedAt": "2026-03-19T08:12:12.000Z",
  "site": "https://allthings.how",
  "textContent": "OpenClaw is still pre-1.0 and ships new releases frequently — sometimes multiple times a week. Keeping up matters because updates regularly patch security issues, fix platform-specific bugs, and migrate configuration keys. The update process differs depending on how you originally installed OpenClaw, so the first thing you need to know is your install method.\n\n**Quick answer:** For most users, run `openclaw update` in your terminal. It detects your install type, pulls the latest version, runs health checks, and restarts the Gateway automatically.\n\n* * *\n\n## Before you update\n\nYou need two pieces of information before touching anything. First, figure out whether you installed OpenClaw **globally** (via npm or pnpm) or **from source** (via git clone). Second, know how your Gateway is running — either in a foreground terminal session or as a supervised service through launchd (macOS) or systemd (Linux/WSL2).\n\nBack up your configuration before every update. The key paths are:\n\nItem| Path\n---|---\nMain config| `~/.openclaw/openclaw.json`\nCredentials| `~/.openclaw/credentials/`\nWorkspace| `~/.openclaw/workspace`\n\n* * *\n\n## Update OpenClaw with the universal installer\n\nThe preferred update path for any non-Docker install is to re-run the official installer script. It detects an existing installation, upgrades in place, and runs `openclaw doctor` automatically when needed.\n\n\n    curl -fsSL https://openclaw.ai/install.sh | bash\n\n\nRe-run the installer\n\nIf you don't want the onboarding wizard to run again, append `--no-onboard`. For source installs specifically, pass the git install method flag:\n\n\n    curl -fsSL https://openclaw.ai/install.sh | bash -s -- --install-method git --no-onboard\n\n\nSource install update via installer\n\nThe installer will only run `git pull --rebase` if the repo has a clean worktree — no uncommitted changes allowed.\n\n* * *\n\n## Update a global npm/pnpm install\n\nIf you installed OpenClaw globally through a package manager, you can update directly with either npm or pnpm:\n\n\n    npm i -g openclaw@latest\n    pnpm add -g openclaw@latest\n\n\nPick one\n\nBun is explicitly not recommended for the Gateway runtime due to known WhatsApp and Telegram bugs.\n\nAfter the package manager finishes, always run the post-update verification sequence:\n\n\n    openclaw doctor\n    openclaw gateway restart\n    openclaw health\n\n\n* * *\n\n## Update a source (git) install\n\nFor git-based checkouts, the simplest path is the built-in update command:\n\n\n    openclaw update\n\n\nThis single command handles the entire flow. It checks that your worktree is clean, switches to the selected channel (tag or branch), fetches and rebases against upstream, installs dependencies, builds the project and Control UI, runs `openclaw doctor`, and restarts the Gateway. If you want to skip the automatic restart, add `--no-restart`.\n\nYou can also do this manually if you prefer granular control:\n\n\n    git pull\n    pnpm install\n    pnpm build\n    pnpm ui:build\n    openclaw doctor\n    openclaw health\n\n\nManual source update\n\nThe `pnpm build` step is important when you run the packaged `openclaw` binary or use Node to run the `dist/` directory. If you run directly from TypeScript with `pnpm openclaw`, a rebuild is usually unnecessary — but config migrations still apply, so run doctor regardless.\n\n* * *\n\n## Update OpenClaw in Docker\n\nDocker-based installs don't use the `openclaw update` CLI command. Instead, you stop the running container, pull the latest image, and start a new container.\n\n\n    docker stop openclaw\n    docker pull openclaw/openclaw:latest\n    docker run -d --name openclaw openclaw/openclaw:latest\n\n\nStandard Docker update\n\nMake sure you use the same volume mounts and startup flags from your original `docker run` or `docker-compose` configuration. Your config and workspace data will carry over as long as the volumes are mounted correctly.\n\n⚠️\n\nIf you're running OpenClaw through a managed hosting provider like Hostinger, the container registry image may lag behind the official release by a couple of days. The :latest tag on a provider's registry doesn't always match the most recent OpenClaw release. Check the image tag or SHA against the official GitHub releases to confirm you're getting the version you expect.\n\nFor Hostinger VPS specifically, the pull command may point to their own registry rather than Docker Hub:\n\n\n    docker pull ghcr.io/hostinger/hvps-openclaw:latest\n\n\nIf your hosting provider's Docker manager has a GUI, you can also stop the container, click the options menu, and select \"Update\" to trigger the same pull-and-restart flow.\n\n* * *\n\n## Update via the Control UI\n\nOpenClaw's web-based Control UI includes an **Update & Restart** button (RPC endpoint: `update.run`). This only works for source (git checkout) installs. It runs the same update flow as the CLI command, writes a restart sentinel with a structured report, restarts the Gateway, and pings the last active session with the result. If the rebase fails, the Gateway aborts and restarts without applying the update — no half-applied states.\n\n* * *\n\n## Switch between stable, beta, and dev channels\n\nOpenClaw supports three update channels. You can switch between them on both git and npm installs:\n\n\n    openclaw update --channel stable\n    openclaw update --channel beta\n    openclaw update --channel dev\n\n\nChannel| Behavior\n---|---\nstable| Checks out the latest non-beta tag, then builds and runs doctor\nbeta| Checks out the latest `-beta` tag, then builds and runs doctor\ndev| Checks out `main`, fetches upstream, rebases; includes preflight lint and build check\n\nThe channel choice is persisted in your config. For a one-off update to a specific version or git ref without changing your channel, use the `--tag` flag:\n\n\n    openclaw update --tag main\n    openclaw update --tag 2026.3.13\n\n\nOne-off target override\n\nTo preview what an update would do without actually applying it, add `--dry-run`.\n\n* * *\n\n## Enable the auto-updater\n\nThe Gateway includes a built-in auto-updater, but it's off by default. You enable it in `~/.openclaw/openclaw.json`:\n\n\n    {\n      \"update\": {\n        \"channel\": \"stable\",\n        \"auto\": {\n          \"enabled\": true,\n          \"stableDelayHours\": 6,\n          \"stableJitterHours\": 12,\n          \"betaCheckIntervalHours\": 1\n        }\n      }\n    }\n\n\nAuto-updater config example\n\nOn the stable channel, the auto-updater waits the configured delay hours after detecting a new version, then applies a deterministic per-install jitter to spread rollouts across installations. The beta channel checks hourly by default and applies immediately when an update is found. The dev channel never auto-applies — you must run `openclaw update` manually.\n\n**Tip:** Run `openclaw update --dry-run` before enabling automation to see exactly what the updater would do.\n\nOn npm installs, the Gateway also logs an update hint at startup when a newer version is available on your current channel. Disable that with `update.checkOnStart: false` in your config.\n\n* * *\n\n## Always run openclaw doctor\n\nEvery update should end with `openclaw doctor`. It's the \"safe update\" command — intentionally boring, but critical. It migrates deprecated config keys, audits DM policies for risky settings, checks Gateway health, detects and migrates older gateway services (launchd, systemd, legacy schtasks), and on Linux ensures systemd user lingering so the Gateway survives logout.\n\nIf you're on a source install, doctor will offer to run `openclaw update` first. Read its output carefully — it often tells you exactly what to fix.\n\n* * *\n\n## Restart the Gateway after updating\n\nThe `openclaw update` command restarts the Gateway by default, but if you updated manually or used `--no-restart`, you need to restart it yourself:\n\n\n    openclaw gateway restart\n\n\nFor supervised services, use the platform-specific restart command:\n\nPlatform| Command\n---|---\nmacOS (launchd)| `launchctl kickstart -k gui/$UID/ai.openclaw.gateway`\nLinux (systemd)| `systemctl --user restart openclaw-gateway.service`\nWindows (WSL2)| `systemctl --user restart openclaw-gateway.service`\n\nThese commands only work if the service is installed. If it isn't, run `openclaw gateway install` first. Prefer `openclaw gateway restart` over manually killing PIDs — it handles the service lifecycle cleanly.\n\n* * *\n\n## Roll back or pin to a specific version\n\nIf an update breaks something, you can pin to a known-good version. For global installs, install the exact version you want:\n\n\n    npm i -g openclaw@2026.3.12\n\n\nCheck the current published version with `npm view openclaw version` to confirm what's available. Then run doctor and restart.\n\nFor source installs, you can pin by date. This checks out the state of `main` as it was on a specific day:\n\n\n    git fetch origin\n    git checkout \"$(git rev-list -n 1 --before=\"2026-01-01\" origin/main)\"\n    pnpm install\n    pnpm build\n    openclaw gateway restart\n\n\nPin to a date (example: Jan 1, 2026)\n\nTo return to the latest version later, just check out main and pull:\n\n\n    git checkout main\n    git pull\n\n\n📌\n\nDowngrades require confirmation because older versions can break your current configuration. Always run openclaw doctor after rolling back.\n\n* * *\n\n## Check your current version and update status\n\nTo see what version you're running, which channel you're on, and whether an update is available:\n\n\n    openclaw update status\n\n\nAdd `--json` for machine-readable output. The most recent stable release is version 2026.3.13, published on March 14, 2026.\n\n* * *\n\nIf none of the above works, run `openclaw doctor` one more time and read every line of its output — it's designed to surface the exact problem. The OpenClaw troubleshooting docs and the project's Discord server at discord.gg/clawd are the two best places to get help when you're stuck.",
  "title": "How to Update OpenClaw (Every Install Method Covered)",
  "updatedAt": "2026-03-19T08:12:14.344Z"
}