Install OpenClaw on Mac
From zero to a working AI agent in 30 minutes. No coding experience needed.
What we'll cover
What you need before starting
Before we begin, make sure you have:
- A Mac (any Mac from the last 5-6 years will work. M1/M2/M3/M4 chips are ideal)
- macOS 13 (Ventura) or newer
- At least 8GB of RAM (check: Apple menu > About This Mac)
- An internet connection
- About 30 minutes of your time
If you want your AI agent running 24/7, a Mac Mini is perfect. It's quiet, uses minimal power, and you can tuck it away. But any Mac works for getting started, including a MacBook.
Install Homebrew (the Mac package manager)
Homebrew is a tool that makes it easy to install software on your Mac. Think of it as an app store for developer tools. You only need to install it once.
How to open Terminal: Press Cmd + Space to open Spotlight, type "Terminal", and hit Enter.
Paste this command into Terminal and press Enter:
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
It will ask for your Mac password (the one you use to log in). Type it and press Enter. You won't see the characters as you type. That's normal.
This takes a few minutes. Wait until you see your terminal prompt again (the % or $ at the end).
If you've installed it before, you can skip this step. Check by running brew --version. If you see a version number, you're good.
Important for Apple Silicon Macs (M1/M2/M3/M4): After installing, Homebrew might ask you to run two additional commands. They'll look something like this:
echo >> ~/.zprofile
echo 'eval "$(/opt/homebrew/bin/brew shellenv)"' >> ~/.zprofile
eval "$(/opt/homebrew/bin/brew shellenv)"
If Homebrew tells you to run these, do it. If it doesn't mention it, skip this.
Install Node.js
Node.js is the software that OpenClaw runs on. You don't need to know anything about it. Just install it.
brew install node@22
Wait for it to finish. You'll see some output scrolling by. When you see your prompt again, it's done.
Verify it worked:
node --version
You should see something like v22.x.x. If you do, you're good. If you get "command not found", you may need to add Node to your path:
echo 'export PATH="/opt/homebrew/opt/node@22/bin:$PATH"' >> ~/.zshrc && source ~/.zshrc
Install OpenClaw
Now the main event. One command:
curl -fsSL https://openclaw.ai/install.sh | bash
This downloads and installs OpenClaw. It takes a minute or two.
Alternatively, you can install via npm:
npm install -g openclaw
Verify it worked:
openclaw --version
You should see a version number. If you do, OpenClaw is installed.
Get your AI API key
OpenClaw needs an AI brain to think with. We recommend Claude by Anthropic. It's the best for business tasks, writing, and general intelligence.
- Go to console.anthropic.com
- Create an account (or sign in)
- Go to API Keys in the left sidebar
- Click Create Key
- Give it a name (e.g., "OpenClaw")
- Copy the key. Save it somewhere safe. You'll need it in the next step.
Anthropic charges based on usage. Most people spend $5-50 NZD per month. Light use (a few messages a day) is very cheap. Heavy use (building websites, long conversations) costs more. You can set a spending limit in your Anthropic dashboard.
OpenClaw also works with OpenAI (GPT-4), Google Gemini, Ollama (free, local models), and many others. Claude is the recommended starting point. You can add more later.
Run the setup wizard
OpenClaw has a built-in wizard that guides you through the rest of the setup. Run:
openclaw onboard --install-daemon
The wizard will walk you through:
- Gateway setup — choose "local" (your machine)
- API key — paste the Anthropic key from Step 5
- Channels — we'll set up Telegram in the next step
- Agent identity — give your agent a name and personality
The --install-daemon flag makes OpenClaw start automatically when your Mac boots up. This means your agent is always on, even after a restart.
The wizard will ask if you want QuickStart or Advanced. Choose QuickStart for your first setup. You can always change settings later with openclaw configure.
Connect Telegram
Telegram is the easiest way to talk to your agent. It's free and works on your phone, tablet, and computer. Here's how to connect it:
Create a Telegram bot
- Open Telegram and search for @BotFather (make sure it has the blue verified checkmark)
- Send the message:
/newbot - BotFather will ask for a name. Type whatever you want (e.g., "My AI Agent")
- BotFather will ask for a username. This must end in "bot" (e.g., "myagent_nz_bot")
- BotFather will give you a token. It looks like:
123456789:ABCdefGHIjklMNOpqrsTUVwxyz - Copy this token
Add the token to OpenClaw
If the setup wizard asked for it, you've already done this. If not, run:
openclaw configure --section channels.telegram
Paste your bot token when prompted.
Start the gateway and approve yourself
openclaw gateway start
Now open Telegram and send a message to your bot. Your first message will trigger a pairing request. Back in Terminal, run:
openclaw pairing list telegram
You'll see a pairing code. Approve it:
openclaw pairing approve telegram YOUR_CODE
Replace YOUR_CODE with the actual code shown.
Send another message to your bot on Telegram. It should respond. You now have a working AI agent you can message from your phone.
Give your agent an identity
This is what makes OpenClaw special. You can give your agent a personality, a role, and rules about how it should behave. This is done through simple text files in your workspace.
The key files
SOUL.md
Who your agent is. Its personality, values, and purpose. Think of it as a soul transplant.
IDENTITY.md
How your agent sounds. Its tone, style, and communication rules.
USER.md
Who you are. Your name, timezone, role, preferences. Helps your agent personalise its work.
AGENTS.md
Operating instructions. What your agent should do, how it should prioritise, daily routines.
MEMORY.md
Long-term memory. Important facts, decisions, and context your agent should always know.
To edit these files:
openclaw edit soul
Or navigate to the workspace folder directly:
open ~/.openclaw/workspace
Example SOUL.md for a tradie's assistant
# SOUL.md
You are Jake's AI assistant. You help him run his plumbing
business in Tauranga, New Zealand.
You are practical, direct, and always thinking about saving
Jake time. You write in plain NZ English. No jargon. No fluff.
You help with: quoting jobs, writing emails to clients,
scheduling, invoicing follow-ups, and finding suppliers.
You never make financial decisions. You never send messages
to clients without Jake's approval. When in doubt, ask.
Tell your agent about your business, your clients, your style. The more context you give it, the more useful it becomes. You can always update these files later.
Start the gateway (keep it running)
The gateway is the engine that keeps your agent running in the background. If you used --install-daemon in Step 6, it's already running as a service and will start automatically on boot.
Check the status:
openclaw gateway status
If it says "running", you're set. If not:
openclaw gateway start
Useful commands
openclaw status
Full system overview
openclaw gateway status
Check if gateway is running
openclaw gateway start
Start the gateway
openclaw gateway stop
Stop the gateway
openclaw gateway restart
Restart (after config changes)
openclaw logs --follow
Watch live logs
openclaw dashboard
Open the web dashboard
openclaw update
Update OpenClaw
Send your first message
Open Telegram. Message your bot. Try something like:
Then try something useful:
You have your own AI agent. It's running on your machine, it knows who you are, and it's ready to work. Start with one task a day and build from there.