Skip to main content
HowOpenClawv2026.3.24

Install & First Message

Install OpenClaw, run the setup wizard, and send your first message.

By the end of this page, you'll have a running Gateway and will have sent your first message through the built-in web interface.

Time: ~15 minutes


Step 1 — Install

Open a terminal and run the installer for your platform:

Review installer scripts before running

Piping a remote script directly to bash executes code with your full user permissions. You can inspect the script at https://openclaw.ai/install.sh before running — good practice for any installer from the internet.

macOS / Linux / WSL2:

curl -fsSL https://openclaw.ai/install.sh | bash

Windows (PowerShell):

iwr -useb https://openclaw.ai/install.ps1 | iex

The installer will attempt to set up Node.js if it isn't present, and adds openclaw to your PATH. OpenClaw requires Node.js 22.14 or later (Node 24 recommended). If the installer fails with a Node version error, install it manually first:

# macOS/Linux — using nvm
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/HEAD/install.sh | bash
nvm install 24

Then re-run the installer. When it finishes, verify it worked:

openclaw --version

Prefer npm? You can also install globally:

npm install -g openclaw@latest

Step 2 — Run the setup wizard

openclaw onboard --install-daemon

The wizard walks you through four things:

  1. Your AI provider — Choose Anthropic (Claude), OpenAI (GPT), or Google (Gemini) and enter your API key. If you don't have one yet: get it from Anthropic, OpenAI, or Google Gemini — create an account, go to API Keys, and copy it. This is required to continue.

  2. Your workspace — Where files the agent creates will live. The default (~/.openclaw/workspace) is fine.

  3. Channel setup — You can skip this for now. You'll connect a real channel in a later step.

  4. Daemon install — This installs OpenClaw as a background service so it starts automatically. Say yes.

When the wizard finishes, your config lives at ~/.openclaw/openclaw.json.


Step 3 — Start the Gateway

If the wizard completed successfully and you said yes to the daemon, the Gateway is already running — skip to the check below.

If you're not sure, or the wizard didn't finish cleanly, start it manually:

openclaw gateway

Check that it's running:

openclaw gateway status

You should see output like:

Gateway: running (pid 12847, uptime 0h 0m)
Channels:
  ✓ webchat      ready
Automations: 0 active

The key line is Gateway: running. If you see it, the Gateway is up.


Step 4 — Send your first message

Open the WebChat interface in your browser:

openclaw dashboard

This opens http://localhost:18789 — the built-in chat interface. You'll see a chat window. Type something and press Enter. Your agent will respond.

WebChat is always available as long as the Gateway is running. No setup required — it's built in.


What just happened

When you sent that message, here's what OpenClaw did:

  1. Received your message via the Gateway (port 18789)
  2. Loaded your configuration from ~/.openclaw/
  3. Sent the message to your AI provider's API
  4. Streamed the response back to your browser

The files created during setup:

~/.openclaw/
├── openclaw.json    ← Your main config
├── SOUL.md          ← Your agent's personality (you'll edit this next)
├── USER.md          ← Information about you
├── MESSAGING.md     ← Channel routing rules
└── workspace/
    ├── MEMORY.md    ← Grows over sessions; agent writes notes here
    └── HEARTBEAT.md ← Standing context; things always in scope

Troubleshooting

ProblemFix
openclaw: command not foundRestart your terminal or add npm's global bin to $PATH
Wizard fails on Node versionRun node --version — need 22.14+ (Node 24 recommended). Install via nvm install 24
Gateway won't startCheck logs: openclaw logs — usually a port conflict (change gateway.port in config)
No response in WebChatMake sure your API key is valid and has credit