Setup guide14 minUpdated 2026-05-06

Run OpenClaw on a VPS the right way.

Running OpenClaw on your laptop is fine until you close the lid. A $5–$15 VPS turns it into an always-on assistant your team can reach from anywhere. This guide picks a provider, sizes the instance, and walks the deploy end-to-end.

Quick answers

  • What's the cheapest VPS for OpenClaw?

    Hetzner CPX11 at €5/month (2 vCPU, 4 GB RAM) for personal chat-only use. Below 4 GB Docker becomes unstable during skill loading. For genuinely free, Oracle Cloud Free Tier gives 2 ARM vCPU + 12 GB RAM — account approval is luck-based but it works when granted.
  • Which VPS provider is best for OpenClaw?

    Hetzner if you're in Europe — best price-to-performance by ~2.5x. DigitalOcean for cleanest UX and the 1-Click app. Linode for mature platform. Vultr for many regions. Both Hetzner and DO are reliable picks for production.
  • How big a VPS do I need?

    Personal chat-only: 2 vCPU / 4 GB RAM. Browser automation: 4 vCPU / 8–16 GB. Multi-agent (5+): 8 vCPU / 32 GB. The sizer below recommends a spec from your workload.
  • Should I use the DigitalOcean 1-Click OpenClaw?

    Fine for getting started — installs OpenClaw, NGINX, and a default config in 60 seconds. But it ships with the gateway publicly bound behind only NGINX, which is not enough. Harden it with the day-1 security checklist immediately after.
  • Can I run OpenClaw on a free VPS?

    Oracle Cloud Free Tier (2 ARM vCPU, 12 GB RAM) genuinely works. AWS free tier (1 GB RAM t2.micro) does not — OOMs during skill loading. GCP free tier same problem. Stick with Oracle for free.

When you outgrow your laptop

Why a VPS

A laptop is a fine place to start with OpenClaw. The moment you want it always-on — to receive Telegram messages, run cron jobs, react to events while you sleep — it has to live somewhere with reliable power and network. That's a VPS.

The break-even point is about a week of consistent use. By then, the friction of "ugh, my laptop closed and the agent missed three messages" outweighs the 30-minute VPS setup.

Right-size first

Sizing calculator

Don't over-provision. Most personal setups are happy on 4 GB of RAM forever; the moment you add browser automation that jumps to 8 GB. Match the size to your real workload.

VPS sizer

vCPU

2

RAM

8 GB

Disk

80 GB SSD

Hetzner CPX21 / DO s-2vcpu-8gb

$12–$20/mo

Comfortable headroom for a few channels and occasional browser use.

Honest comparison

Pick a provider

ProviderPrice (4 GB)StrengthsWatch out for
Hetzner CPX21€7/moBest price/perf, dedicated coresEU only, KYC for some accounts
DigitalOcean$24/moEasiest UX, 1-Click app, great docsPricier, shared cores
Linode (Akamai)$24/moSolid network, mature platformPricier than Hetzner
Vultr$12/moMany regions, hourly billingNewer accounts get rate-limited
Contabo VPS S€5/moCheapest in segmentOversold; performance varies
Oracle Free Tier$0ARM, 12 GB RAM, genuinely freeAccount approval is luck-based

Default pick

Hetzner CPX21 if Europe is fine for you, DigitalOcean s-2vcpu-4gb otherwise. Both are reliable; Hetzner gives you ~2.5x the hardware per dollar.

Step 1

Provision the box

We'll use Hetzner Ubuntu 24.04 as the example. The flow is identical on other providers; only the dashboard UI changes.

  • Create the server with Ubuntu 24.04 LTS
  • Add your SSH public key during provisioning (don't accept the password option)
  • Note the server's IP address
  • Set a meaningful hostname like 'openclaw-prod'
  • Add a firewall rule allowing only SSH (port 22) from your IP if possible
# From your laptop
ssh root@<server-ip>

Step 2

Harden the OS

Before anything else, lock down the server. Five steps, ten minutes, dramatically reduces your attack surface.

# 1. Update everything
apt update && apt upgrade -y

# 2. Create a non-root user
adduser openclaw
usermod -aG sudo openclaw
mkdir -p /home/openclaw/.ssh
cp ~/.ssh/authorized_keys /home/openclaw/.ssh/
chown -R openclaw:openclaw /home/openclaw/.ssh
chmod 700 /home/openclaw/.ssh
chmod 600 /home/openclaw/.ssh/authorized_keys

# 3. Disable root SSH and password auth
sed -i 's/#PermitRootLogin yes/PermitRootLogin no/' /etc/ssh/sshd_config
sed -i 's/#PasswordAuthentication yes/PasswordAuthentication no/' /etc/ssh/sshd_config
systemctl restart ssh

# 4. Enable a firewall (UFW)
apt install -y ufw
ufw default deny incoming
ufw default allow outgoing
ufw allow 22/tcp
ufw enable

# 5. Test the new user works BEFORE closing your root session
# In a new terminal:
ssh openclaw@<server-ip>

Test before disconnecting

Don't close your root session until you've successfully SSH'd in as the new user from a separate window. If something broke in step 3, you'll need root to fix it.

Step 3

Install OpenClaw

As your new openclaw user:

# Install Node 22+
curl -fsSL https://deb.nodesource.com/setup_22.x | sudo -E bash -
sudo apt-get install -y nodejs

# Install OpenClaw
curl -fsSL https://openclaw.ai/install-cli.sh | bash

# Onboard
openclaw onboard

In the onboarding wizard, choose:

  • QuickStart install option
  • Anthropic, OpenAI, or OpenRouter as your provider
  • Bind to 127.0.0.1 (the default — don't change this)
  • Skip channel setup for now; we'll do that after the gateway is stable

Step 4

Run as a service

The gateway needs to survive reboots and crashes. systemd is the answer.

openclaw service install
sudo systemctl start openclaw-gateway
sudo systemctl enable openclaw-gateway
sudo systemctl status openclaw-gateway

The installed service file restarts on failure with exponential backoff and writes logs to journald, where journalctl -u openclaw-gateway -f streams them.

Step 5

Logs + monitoring

You don't need a Datadog account. The minimum viable monitoring for a single-VPS OpenClaw setup is:

  • journalctl for live logs: journalctl -u openclaw-gateway -f
  • A weekly email digest of "is the gateway up, what was the LLM bill" — the agent itself can run this as a cron job.
  • Healthcheck.io ping: have the gateway ping a free Healthcheck endpoint every 5 min so you get paged if it goes silent.
  • API spend alerts at the LLM provider — Anthropic and OpenAI both let you set them at 50%, 80%, 100% of your monthly cap.

Anything beyond that is overkill for a single-VPS setup. Once you have multiple agents on multiple boxes, that's when actual monitoring tooling earns its keep.

FAQ

Which VPS provider is best for OpenClaw?
Hetzner if you're in Europe or don't mind the Frankfurt/Helsinki latency — best price-to-performance by a wide margin. DigitalOcean if you want the cleanest UX and the 1-Click app. Linode if you're already on Linode. Vultr or Contabo for budget tiers.
What's the cheapest VPS that actually works?
$5/mo (Hetzner CPX11 / DO s-2vcpu-4gb) for chat-only personal use. Below 4 GB RAM, Docker becomes unstable during skill loading. Below 2 vCPU, the gateway and an active session fight for CPU.
Should I use the DigitalOcean 1-Click?
It's fine for getting started — installs OpenClaw, NGINX, and a default config in 60 seconds. Just remember to harden it after: it ships with the gateway bound publicly behind nothing more than NGINX, which is not enough.
Can I run OpenClaw on a free VPS?
Briefly. Oracle Cloud Free Tier (2 ARM vCPU, 12 GB RAM) genuinely works. AWS free tier (t2.micro, 1 GB RAM) does not — you'll OOM during skill loading. Skip the GCP free tier for the same reason.
How do I make sure it stays running?
Run as a systemd service. `openclaw service install` registers one for you. Combine with `restart-on-failure` and a health check, and the gateway recovers from anything short of a kernel panic without intervention.
Is it OK to expose the OpenClaw web UI publicly?
Not as-is. The gateway has no auth. Either keep it bound to 127.0.0.1 and reach it via SSH tunnel/Tailscale, or put it behind a reverse proxy with strong authentication. We recommend Tailscale — it's the easiest secure path and works on every device.

Want OpenClaw without the ops?

Provision is the managed OpenClaw cloud — agents, channels, browser, and skills, all running. $99/mo. 48-hour free trial.