The OpenClaw CLI manages a personal AI assistant and its Gateway. The commands you use most often are setup, service control, configuration, and diagnostics. Start with the task you need to perform, then ask your installed CLI for the flags available in that version.

Independent guide. References checked on October 2, 2026. Examples follow the official CLI reference; they are not a record of a deployment test.

Start with the version and command help

openclaw --version
openclaw --help
openclaw gateway --help

Save the version number when reporting a problem. Instructions written for an older release can use a different schema or setup flow. If the binary is missing, use our installation guide.

Set up an assistant

openclaw onboard

Onboarding guides you through working model access and Gateway setup. Use it for a first installation or when resuming setup. openclaw configure opens the configuration wizard for subsequent settings.

You do not need to scaffold a software project to operate OpenClaw. The earlier openclaw new, openclaw dev, and openclaw build examples on this site did not describe the supported assistant setup workflow and have been removed. Use the installed command help and onboarding documentation for your version.

Manage the Gateway

For a configured installation that should keep running in the background:

openclaw gateway install
openclaw gateway status
openclaw gateway health

If onboarding is still running a foreground Gateway, stop it before installing the service. The service reference explains how OpenClaw uses the platform's service manager.

Once installed, the lifecycle commands are:

openclaw gateway stop
openclaw gateway start
openclaw gateway restart

A service restart affects active work. Check for a running task before restarting just to refresh a setting. For a temporary foreground process, consult openclaw gateway run --help; do not start a second listener while the managed service owns the same port.

Open the Control UI

openclaw dashboard

Run this on the machine hosting your Gateway for a local dashboard. A VPS needs a remote-access path such as an SSH tunnel; opening your laptop's localhost address does not automatically reach your server. Follow the server guide for that setup.

Inspect and change configuration

openclaw config file
openclaw config get agents.defaults.workspace
openclaw config schema
openclaw config validate

The default file is ~/.openclaw/openclaw.json, in JSON5 format. config file tells you the active path; that is more useful than assuming every profile uses the default.

Change one setting and validate it:

openclaw config set agents.defaults.heartbeat.every "2h"
openclaw config validate

This example sets a heartbeat interval; use an interval suited to your workload and budget. For structured values, see the config CLI documentation before choosing JSON flags or patch files. Avoid pasting API keys directly into shell commands because they may remain in shell history.

Read our configuration guide for the distinction between runtime settings and workspace instructions.

Diagnose failures in order

openclaw status
openclaw doctor
openclaw logs --follow

Use status to understand the installation, doctor for checks and repair guidance, and logs to watch the actual error. Review repair proposals before using mutation flags; a diagnostic command and a repair command have different effects.

Symptom First useful check Next step
Command not found Shell PATH and installed runtime Installation guide
Dashboard connection refused openclaw gateway status Service or tunnel
Config rejected openclaw config validate Correct the named field
Dashboard opens, no model reply openclaw doctor and logs Provider credentials or quota
Browser chat works, channel does not Channel setup and pairing Troubleshooting guide

Share only redacted diagnostic output. Configuration, logs, and backups can contain account details or private conversation data.

A practical daily command set

openclaw --version
openclaw gateway status
openclaw config validate
openclaw dashboard

Use this sequence after an upgrade or configuration change, then send one ordinary message. It verifies the CLI, service, schema, and the actual assistant experience separately.

FAQ

Which command creates my first assistant?

Use openclaw onboard, then complete model access and Gateway setup. Follow the local setup guide for the full sequence.

Is openclaw config list the right way to inspect settings?

The current config reference documents get, set, unset, patch, file, schema, and validate. Use config get <path> for a specific value and your installed help for supported subcommands.

Must I run commands from a project folder?

Ordinary Gateway and configuration commands use the active OpenClaw state and profile. Repository build commands, custom scripts, and workspace file operations can have their own directory requirements; they are separate from assistant onboarding.