Installing OpenClaw
Complete installation guide for macOS, Linux, and Windows. Get OpenClaw running on your machine in 10 minutes or less.
System Requirements
- Operating System: macOS, Linux, or Windows (WSL2 strongly recommended for Windows)
- Node.js: Version 22 or higher
- Git: For cloning the repository (optional if using npm)
- RAM: Minimum 4GB, 8GB+ recommended
- Disk Space: At least 2GB free
Method 1: NPM Installation (Recommended)
The fastest way to get OpenClaw running is via npm. This installs the latest stable release globally on your system.
Step 1: Install OpenClaw
npm install -g openclaw@latestOr if you prefer pnpm:
pnpm add -g openclaw@latestStep 2: Run the Onboarding Wizard
OpenClaw includes an interactive setup wizard that guides you through configuration:
openclaw onboard --install-daemonThe wizard will help you:
- Set up your workspace directory
- Configure AI model providers (OpenRouter, Anthropic, OpenAI)
- Connect messaging channels
- Install the system daemon for auto-start
Method 2: From Source (Development)
For developers who want to customize OpenClaw or contribute to the project, install from source:
Step 1: Clone the Repository
git clone https://github.com/openclaw/openclaw.gitcd openclawStep 2: Install Dependencies
pnpm installpnpm ui:buildpnpm buildStep 3: Run the Onboarding Wizard
pnpm openclaw onboard --install-daemonPlatform-Specific Notes
macOS
OpenClaw includes a native macOS menu bar app with voice control, Canvas UI, and system integration. The daemon runs via launchd.
Install menu bar app:
cd platforms/mac && pnpm install && pnpm buildLinux
OpenClaw runs as a systemd user service on Linux. The daemon auto-starts on login.
Check daemon status:
openclaw statusWindows (WSL2)
For Windows users, WSL2 (Windows Subsystem for Linux) is strongly recommended. Native Windows support is experimental.
- Install WSL2 with Ubuntu
- Install Node.js 22+ inside WSL
- Follow the Linux installation steps
Verifying Installation
After installation, verify OpenClaw is working:
openclaw --versionopenclaw statusopenclaw doctorThe openclaw doctor command checks your configuration for common issues and suggests fixes.
Starting the Gateway
The Gateway is OpenClaw's control plane that manages sessions, channels, and tools. Start it manually:
openclaw gateway startOr run in verbose mode for debugging:
openclaw gateway --port 18789 --verboseIf you installed the daemon with --install-daemon, the Gateway starts automatically on boot.
Common Issues
Node.js Version Error
OpenClaw requires Node.js 22 or higher. Check your version:
node --versionUpdate Node.js using nodejs.org or nvm.
Permission Errors
If you encounter permission errors during npm install, avoid using sudo. Instead, configure npm to use a user-owned directory.
Gateway Won't Start
Check if another process is using port 18789:
lsof -i :18789Kill the conflicting process or configure a different port in your config.
