Beginner guide · OpenClaw
How to set up OpenClaw safely (Mac, Windows, Linux)
Short answer: run the official installer (curl -fsSL https://openclaw.ai/install.sh | bash on a Mac or Linux, or the PowerShell one on Windows), pick Quick start, check openclaw gateway status, open openclaw dashboard and send one test message. Then run openclaw security audit before you connect Telegram or any other app. OpenClaw is free; you pay for the AI model you connect (OpenClaw docs).
Updated · By BotsDoThat
Every command is from OpenClaw's official docs, linked inline and checked Dec 2, 2026. OpenClaw updates often; if a step looks different, follow the linked page.
Before you start
- What OpenClaw is. A free, open-source AI assistant you run on your own computer or server. It answers in chat apps you already use (Telegram, WhatsApp, Discord, Slack, iMessage and more) and can browse, handle files and run scheduled jobs (OpenClaw FAQ).
- A machine you don't mind giving to an agent. Microsoft's security team advises a dedicated virtual machine or spare device with its own accounts (Microsoft Security Blog). Why: is OpenClaw safe?
- An AI model. Onboarding can reuse a Claude Code or Codex login, or an API key. Costs: switch OpenClaw to a cheaper model and set a cap with set spend limits and usage alerts on your AI accounts.
- Node.js 24.16+ or 26.1+ (26 recommended). The installer adds it if it's missing (install docs).
How to set up OpenClaw: 7 steps
- Pick the computer it will live on. OpenClaw runs on macOS, Linux or Windows, and its Gateway keeps running in the background so you can message it all day. Security teams advise a spare computer or a separate virtual machine with its own accounts, not the laptop that holds your bank and work logins.
- Have an AI model ready. Onboarding can reuse an existing Claude Code or Codex login, or you can paste an API key from a model provider. You pay that provider (or use the plan you already have); OpenClaw itself is free.
- Run the installer. macOS, Linux or WSL2: curl -fsSL https://openclaw.ai/install.sh | bash. Windows PowerShell: iwr -useb https://openclaw.ai/install.ps1 | iex. On Windows the docs recommend the Windows Hub desktop app as the easiest route. The installer adds Node if it's missing and starts onboarding.
- Choose Quick start in onboarding. Quick start finds the AI access you already have, checks it with a real reply, saves the settings and opens the dashboard. Say Yes to “Keep OpenClaw running in the background?” if you want it always on. Custom setup walks through every option.
- Check it's running. Run openclaw gateway status (it should be listening on port 18789), then openclaw dashboard to open the Control UI in your browser and send one test message.
- Run the security audit. Run openclaw security audit. The defaults keep the Gateway on your own machine and make strangers who message your bot wait for a pairing code; the audit tells you if a setting has drifted.
- Connect one chat app last. Telegram is the fastest (just a bot token). Unknown senders get an 8-character pairing code; approve yourself with openclaw pairing approve telegram <CODE>, and nobody else.
The install commands
macOS, Linux or WSL2
curl -fsSL https://openclaw.ai/install.sh | bash
Windows (PowerShell)
iwr -useb https://openclaw.ai/install.ps1 | iex
Prefer an app? Windows: the Windows Hub companion app (a signed installer). Mac: the menu bar app from OpenClaw's GitHub releases (install docs). Already manage Node yourself? npm install -g openclaw@latest, then openclaw onboard --install-daemon.
Piping a web script into your shell means trusting that site. Copy the command only from the official docs page.
Check it works before you add anything
openclaw gateway status openclaw dashboard openclaw security audit
- Status should show the Gateway listening on port 18789.
- Dashboard opens the Control UI in your browser. Type a message; you should get an AI reply (Getting started).
- Security audit checks your settings against OpenClaw's safe defaults: Gateway bound to your own machine, unknown DMs answered with a pairing code, groups allowlisted (OpenClaw security).
Connect Telegram (or another chat app)
The docs call Telegram the fastest channel to set up: it only needs a bot token from @BotFather. The default DM policy is pairing: a stranger who messages your bot gets a code and nothing happens until you approve it (OpenClaw Telegram docs).
openclaw pairing list telegram openclaw pairing approve telegram <CODE>
Codes are 8 characters and expire after an hour. Approve only yourself. You can also approve in the dashboard under Settings, then Channels, then DM access requests (Pairing docs). Running Hermes Agent instead? Hermes Agent Telegram setup.
Before you let it act: 6 rules
- Use a spare machine and separate accounts. Not your main email or bank logins (Microsoft).
- Keep the Gateway private. Don't expose it to the internet; if you must reach it remotely, read OpenClaw's exposure runbook first (OpenClaw security).
- Keep pairing on. Never set the DM policy to open; approve only people you know.
- Treat skills as code. Install only skills from authors you trust and read them first: is OpenClaw safe?
- Treat what it reads as untrusted. Emails and web pages can hide instructions for the agent (OpenClaw prompt injection): keep hidden instructions in emails and web pages from steering your bot.
- Start read-only, and back it up. A morning summary before anything that sends, buys or deletes; then back up your AI agent so you never lose its memory (and move it to a new computer) and keep an AI agent from deleting your files.
If setup fails
| What you see | What to do |
|---|---|
openclaw not found | npm's global folder isn't on your PATH. Check node -v and npm prefix -g (install docs) |
| No reply in the dashboard | Run openclaw onboard again to re-check the model sign-in or key |
| Bot connected, but it ignores you | Check for a pending pairing code: openclaw pairing list telegram |
| Anything else | openclaw triage (read-only checks, secrets left out) or openclaw doctor (Getting started) |
To remove it: openclaw uninstall --dry-run --all shows what would go, then openclaw uninstall. Move any workspace you want to keep first (Uninstall docs).
What to hand it first
Any of our 12 blueprints works as instructions for OpenClaw. Good first ones: Morning Inbox Briefing and Web Page Watcher. Still choosing? OpenClaw vs Hermes Agent (Hermes has a desktop app: how to install Hermes Agent) or OpenClaw alternatives for beginners. Rather not run a computer at all? Hosted personal agents compared.
Questions
How do I set up OpenClaw?
Install it with the official script (curl -fsSL https://openclaw.ai/install.sh | bash on macOS, Linux or WSL2; iwr -useb https://openclaw.ai/install.ps1 | iex in Windows PowerShell), choose Quick start in onboarding, then check openclaw gateway status and open openclaw dashboard to send a test message. Run openclaw security audit before you connect any chat app.
Is OpenClaw free?
The software is free and open source. The OpenClaw Foundation says it has no paid tier, no hosted service and no token. You pay for the AI model you connect, or reuse a plan you already have (onboarding can use an existing Claude Code or Codex login). A local model can keep everything on your own computer.
How do I install OpenClaw on Windows?
The docs recommend the native Windows Hub companion app (a signed installer) as the easiest desktop route. For the command line, run iwr -useb https://openclaw.ai/install.ps1 | iex in PowerShell. A WSL2 Gateway with the Linux installer also works.
How do I set up OpenClaw on a Mac?
Run curl -fsSL https://openclaw.ai/install.sh | bash in Terminal; it installs Node 26 if you don't have it and starts onboarding. There is also a macOS menu bar app on OpenClaw's GitHub releases page. The background Gateway runs as a LaunchAgent.
How do I connect OpenClaw to Telegram?
Create a bot with Telegram's @BotFather, add its token to OpenClaw (onboarding or openclaw channels add), then message your bot. You'll get a pairing code; approve it with openclaw pairing list telegram and openclaw pairing approve telegram <CODE>. Codes expire after an hour.
Is it safe to set up OpenClaw on my main computer?
Security teams advise against it. Microsoft's security team recommends a dedicated virtual machine or separate device with its own accounts. OpenClaw's defaults are conservative (Gateway on loopback, pairing for unknown senders), but the agent can run tools with whatever access you give it.
OpenClaw setup isn't working. What do I do?
Run openclaw triage: it runs read-only health checks and writes a diagnosis you can read or hand to a coding agent, with secrets left out. openclaw doctor shows the findings directly. If the shell says openclaw isn't found, npm's global folder is usually missing from your PATH.
How do I uninstall OpenClaw?
Run openclaw uninstall --dry-run --all to preview what would be removed, then openclaw uninstall (or --all for everything: service, state, workspace and app). Move any workspace you want to keep first.
Next step
Write your first job's rules in the free bot instructions builder (no sign-up, nothing stored) or with the 6-part AI agent instructions template, then paste them into the dashboard chat.