Skip to main content

OpenClaw CLI

The OpenClaw CLI is your primary interface for managing the gateway, agents, channels, and configuration.

Installation

Global Install (npm)

Source Checkout (git)

Usage

Global Options

boolean
Display help for any command
boolean
Display the current version
boolean
Disable ANSI colors in output
string
Use a custom profile for configuration

Core Commands

  • gateway - Run and manage the WebSocket Gateway
  • agent - Run one agent turn via the Gateway
  • channels - Manage connected chat channels
  • config - Get, set, or list configuration values
  • onboard - Interactive onboarding wizard

Management Commands

  • daemon - Manage the Gateway service (launchd/systemd/schtasks)
  • logs - Tail gateway file logs via RPC
  • update - Update OpenClaw and inspect update channel status
  • doctor - Health checks and quick fixes

Getting Help

Use --help with any command to see detailed usage information:

Examples

The CLI requires Node.js 22 or higher. Use node --version to check your version.

Configuration

The CLI reads configuration from ~/.openclaw/openclaw.json by default. Use openclaw config to manage settings:

Environment Variables

string
Override gateway authentication token
string
Override gateway authentication password
string
Disable ANSI colors (set to any value)
string
Use a custom profile for configuration

Next Steps

  1. Run the onboarding wizard: openclaw onboard
  2. Start the gateway: openclaw gateway run
  3. Connect channels: openclaw channels add
  4. Check health: openclaw doctor