Prerequisites
- Node.js 20+ (22 recommended)
- Git
Need OS setup steps first? Use /docs/install-macos-linux or/docs/install-windows-node.
Step 1: Install
Fastest: npm install
npm install -g clawmagic
Or use the one-liner installer (auto-installs Node.js if missing):
curl -fsSL https://clawmagic.ai/install.sh | bash
Or clone and run manually:
git clone https://github.com/clawmagic/clawmagic.git cd clawmagic bash scripts/install.sh
Step 2: Onboard
clawmagic onboard
This walks you through provider setup (add your AI provider API key), agent configuration, and security. If you used the full installer, onboarding opens automatically in your browser.
What the Installer Does
- Verifies Node.js 20+ (auto-installs if missing)
- Installs npm dependencies
- Builds all packages (core, server, CLI, web portal)
- Runs doctor checks
- Installs background gateway service
- Verifies
/healthendpoint - Opens onboarding in your browser
The npm install -g path skips the build step — it installs the pre-built package directly.
Quick Install (CLI Only)
If you prefer terminal-only setup without the web portal:
bash scripts/install.sh --quick
This skips the web portal build (~2 min faster). Onboarding runs in the terminal. Add the portal later anytime with npm run build:web.
Verify It Works
# Check system health node apps/cli/dist/main.js doctor # Or use the shim node clawmagic.mjs doctor
Doctor should report all checks passing. The gateway should be running and http://127.0.0.1:18790/health should respond.
Troubleshooting
node: command not found— install Node.js first via the OS setup guides above.- Gateway not starting — run
node apps/cli/dist/main.js doctorto diagnose. - Port conflict — the installer auto-detects and remaps ports. Check logs at
state/install.log.