How to set up OpenClaw on a Mac Mini

The Mac Mini is the most cost-effective way I know to run OpenClaw in production. One-time hardware cost, a few dollars a month of electricity, and a machine that sits on a shelf and quietly runs your AI agent for years. This guide is what I hand clients when they want to deploy on hardware they own instead of a cloud VPS. Hardware recommendations, macOS configuration, launchd service, remote access, and the numbers I use to decide if a Mac Mini is actually the right call.

Why a Mac Mini for OpenClaw

OpenClaw does not need a lot of compute. It is a Node.js process that reads files, holds a handful of sockets to messaging platforms, and fires off outbound API calls to a model provider. The expensive work happens on Anthropic's servers. Locally you are sizing for a calm background workload that needs to stay running 24/7 with minimal fuss.

A Mac Mini is built for exactly that. Apple Silicon sips power, the chassis runs silently, macOS has excellent sleep-wake behavior, and the hardware lasts a decade. The M4 base model draws about 5 watts at idle and 25 to 30 watts under load. A VPS at comparable specs costs $20 per month. A Mac Mini pays for itself in 30 months and is still going long after.

The break-even math assumes you actually want to own the machine. If your agent is for a client and you are billing them, a VPS is still usually the right call because it moves cost off your balance sheet. If this is for you, your own house, and you plan to run the agent for years, the Mac Mini is the right choice.

Which Mac Mini to buy

As of 2026 the clean buy is the base-spec M4 Mac Mini. 16 GB unified memory, 256 GB SSD, $599 at retail. That configuration runs OpenClaw with several skills, a local Ollama model if you want one, and still has headroom for future growth. I deploy on that exact config and have never hit its ceiling for a personal agent.

ConfigurationPriceBest for
M4 base, 16 GB / 256 GB$599Most OpenClaw deployments. The one I recommend.
M4, 24 GB / 512 GB$999Running OpenClaw plus a local Ollama model plus OpenWebUI.
M4 Pro, 24 GB / 512 GB$1,399Overkill for OpenClaw alone. Only if the Mac is also doing video, audio, or ML work.
M2, 16 GB / 256 GB refurb~$499If you find a refurb and want to save $100. Otherwise buy M4.

Do not buy the 8 GB base model. It technically runs OpenClaw, but you will hit memory pressure the first time you load a few skills that use subprocesses (transcription, screenshot tools, anything that shells out). The $200 upgrade to 16 GB is the highest-leverage spend in the whole build.

Initial macOS setup

Set the Mac Mini up as if you were using it as a desktop. Pick a separate local account name like openclaw if you want clean process isolation, or use your personal Apple ID if you are comfortable with that. Either works. Enable FileVault during setup. Then make these changes before installing anything.

  • Disable automatic sleep. System Settings, Energy, Prevent automatic sleeping on power adapter when the display is off. Display sleep is fine. The machine sleep is what kills the agent.
  • Enable wake on network access. Same panel. Lets the machine respond to Tailscale even if it does dip into a light sleep state.
  • Disable Power Nap. Not relevant for a server workload, costs power, safer off.
  • Enable automatic login for the chosen account. If the machine reboots after a power event you want it to come back without manual intervention.
  • Set the system hostname. System Settings, Sharing, edit Computer Name. Set something identifiable like mac-mini-agent. Tailscale will pick up this name.

Install the prerequisites

Install Homebrew first. It is the only package manager you need. Then install Node.js 20 (OpenClaw requires 20+) and git.

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
brew install node git
node --version   # should print v20.x or newer
npm --version

Homebrew puts its binaries in /opt/homebrew/bin on Apple Silicon. Make sure that is on PATH by checking echo $PATH. If not, the Homebrew installer tells you the exact line to add to ~/.zshrc.

Install OpenClaw

Follow the full deployment guide for the canonical install. The macOS-specific notes:

  • Workspace directory: I put it at ~/Library/Application Support/openclaw so it is out of the way and backed up by macOS Time Machine if you enable it. ~/openclaw-workspace is also fine if you prefer things visible.
  • Run the onboard command: openclaw onboard --non-interactive --accept-risk --workspace "$HOME/Library/Application Support/openclaw" --mode local.
  • Skip the systemd step from the VPS guide. You will wire up launchd instead in the next section.

Run OpenClaw as a launchd service

Create a LaunchAgent plist so the gateway starts at login and restarts on crash. Save this as ~/Library/LaunchAgents/ai.openclaw.gateway.plist:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>Label</key><string>ai.openclaw.gateway</string>
    <key>ProgramArguments</key>
    <array>
        <string>/opt/homebrew/bin/openclaw</string>
        <string>run</string>
        <string>--workspace</string>
        <string>/Users/YOUR_USER/Library/Application Support/openclaw</string>
    </array>
    <key>RunAtLoad</key><true/>
    <key>KeepAlive</key><true/>
    <key>StandardOutPath</key><string>/Users/YOUR_USER/Library/Logs/openclaw.log</string>
    <key>StandardErrorPath</key><string>/Users/YOUR_USER/Library/Logs/openclaw.err.log</string>
</dict>
</plist>

Replace YOUR_USER with your actual username. Then load it:

launchctl load ~/Library/LaunchAgents/ai.openclaw.gateway.plist
launchctl list | grep openclaw    # should show the service running

Log rotation is the one gotcha. macOS does not rotate launchd stdout logs automatically. Add a weekly newsyslog.d entry or run a simple cron that truncates the log when it passes 50 MB.

Remote access with Tailscale

Install Tailscale from the App Store. Sign in. That is the whole setup. Now the Mac Mini is reachable from every other device on your Tailscale network with no port forwarding, no static IP, and no VPN server to maintain.

Two things to enable beyond the default:

  • Tailscale SSH. Enable it in the Tailscale app preferences. You can now ssh you@mac-mini-agent from your laptop without managing authorized_keys files. Tailscale handles auth through your identity provider.
  • MagicDNS. On in your Tailscale admin. Gives you mac-mini-agent as a hostname across the tailnet instead of raw IPs.

Do not forward any ports on the home router. The Mac Mini stays behind NAT. Tailscale is the only reachability path. This is a real security win.

Backups

The workspace directory is the state. Snapshot it daily. Two options, pick one or both:

  • Time Machine. If you have an external drive, plug it in, turn on Time Machine, you are done. Hourly local snapshots. Zero config.
  • rsync to cloud. A daily launchd agent that runs rsync -a --delete ~/Library/Application\ Support/openclaw/ user@backup-host:openclaw-backup/. Good if you want off-site redundancy.

Production hardening for the Mac Mini specifically

The main deployment guide covers the cross-platform hardening. These are the macOS-specific extras:

  • Disable guest access. System Settings, Users and Groups, Guest User off. The machine is not a shared workstation.
  • Firewall on. System Settings, Network, Firewall. Allow Tailscale. Block all else. OpenClaw is outbound-only so this breaks nothing.
  • Set up a reboot schedule. Optional but helpful. A monthly pmset scheduled restart clears whatever creeping state has accumulated and keeps macOS patch installs flowing.
  • Enable FileVault if you did not at setup. Disk encryption. If the machine is ever stolen, credentials and workspace state are not readable.

Cost breakdown

Line itemOne-timeMonthly
Mac Mini M4, 16 GB / 256 GB$599
Electricity (M4 at idle + load, US avg $0.15/kWh)~$3
Anthropic API (low-volume personal agent)$20–$60
Tailscale (Personal tier)$0
Domain (optional)~$1
Total$599$24–$64

Comparable VPS deployment at $20 to $30 per month plus the same model costs hits break-even at about 30 months. Most clients I work with keep the Mac Mini running for four to six years without replacing it.

When a Mac Mini is the wrong choice

Three cases where I steer clients toward a VPS instead:

  • Client workloads where you bill the infrastructure. A $20/month line item on an invoice is easier than explaining a $600 capital expense.
  • Homes with unreliable internet or power. A VPS has uptime guarantees. A Mac Mini on a flaky cable connection does not.
  • Deployments that need multi-region failover. Genuinely rare for personal agents, but if it matters, cloud is built for it and a Mac Mini is not.

Everything else, the Mac Mini wins on total cost of ownership.

Want the reference-friendly version?

Get The OpenClaw Deployment Playbook in your inbox. Same six-phase install, full production hardening checklist, pitfalls I see on handoffs. Free. Email required.

Get the Playbook

Or have me build it on your Mac Mini

I ship up the whole thing over Tailscale. Hardware arrives, you plug it in, I handle the rest end-to-end including channels and custom skills. $150/hour. First hour is free.

Book a Free Strategy Call