Intermediate
How to Install OpenClaw on DigitalOcean Droplet [2026 Guide]
Quick Answer
Create a DigitalOcean Droplet ({{price:digitalocean:Basic 1GB}}/mo for 1 GB RAM, or {{price:digitalocean:Basic 2GB}}/mo for 2 GB recommended), use the 1-Click OpenClaw App from the Marketplace for instant deployment, or manually install via Docker Compose. Configure your AI provider keys and messaging apps through the onboarding wizard. Total setup: ~5 minutes with 1-Click, ~15 minutes manual.
Prerequisites
- DigitalOcean account with a payment method
- SSH key added to your DigitalOcean account
- API key from Anthropic (Claude) or OpenAI
- Basic command-line knowledge
1
Create a Droplet for OpenClaw
DigitalOcean offers two paths to deploy OpenClaw:
Option A: 1-Click App (recommended)
Go to the DigitalOcean Marketplace and search for OpenClaw. Click Create OpenClaw Droplet — this pre-installs Docker, OpenClaw, and Nginx reverse proxy. Select the {{price:digitalocean:Basic 2GB}}/mo Droplet (2 GB RAM, 1 vCPU, 50 GB SSD) for reliable performance.
Option B: Manual setup
Go to Create → Droplets, select Ubuntu 24.04 LTS, choose the {{price:digitalocean:Basic 2GB}}/mo plan (minimum {{price:digitalocean:Basic 1GB}}/mo works but 2 GB is recommended), select your SSH key, and create the Droplet.
Option A: 1-Click App (recommended)
Go to the DigitalOcean Marketplace and search for OpenClaw. Click Create OpenClaw Droplet — this pre-installs Docker, OpenClaw, and Nginx reverse proxy. Select the {{price:digitalocean:Basic 2GB}}/mo Droplet (2 GB RAM, 1 vCPU, 50 GB SSD) for reliable performance.
Option B: Manual setup
Go to Create → Droplets, select Ubuntu 24.04 LTS, choose the {{price:digitalocean:Basic 2GB}}/mo plan (minimum {{price:digitalocean:Basic 1GB}}/mo works but 2 GB is recommended), select your SSH key, and create the Droplet.
Tip
The 1-Click App includes pre-configured Nginx with SSL support, saving significant setup time.
2
Connect to your Droplet
Once the Droplet is created, note the IP address from the dashboard. Connect via SSH:
ssh root@YOUR_DROPLET_IPIf you used the 1-Click App, you'll see the OpenClaw welcome message with next steps. For manual setup, update the system first:apt update && apt upgrade -y3
Install Docker (manual setup only)
Skip this step if you used the 1-Click App. Install Docker:
curl -fsSL https://get.docker.com | sh
usermod -aG docker $USER
newgrp dockerVerify installation:docker --version
docker compose version4
Deploy OpenClaw with Docker Compose
Skip this step if you used the 1-Click App. Set up the project:
mkdir -p ~/openclaw && cd ~/openclaw
echo "OPENCLAW_SECRET=$(openssl rand -base64 32)" > .envCreate docker-compose.yml:cat > docker-compose.yml << 'EOF'
version: '3.8'
services:
openclaw:
image: openclaw/gateway:latest
container_name: openclaw
restart: unless-stopped
ports:
- "127.0.0.1:3000:3000"
volumes:
- ./data:/app/data
env_file: .env
environment:
- NODE_ENV=production
EOFStart OpenClaw:docker compose up -d5
Run the onboarding wizard
Access the Control UI via SSH tunnel:
ssh -L 3000:localhost:3000 root@YOUR_DROPLET_IPOpen http://localhost:3000 in your browser. Configure:- AI Provider: Enter your Anthropic or OpenAI API key
- Messaging: Connect WhatsApp, Telegram, Discord, or Slack
- Security: Set gateway authentication password
- Preferences: Language, timezone, agent defaults
Tip
DigitalOcean's 1-Click App configures Nginx with Let's Encrypt SSL, so you can optionally access the UI via your domain over HTTPS instead of SSH tunnel.
6
Configure DigitalOcean Cloud Firewall
Use DigitalOcean's Cloud Firewall (free) for network-level security. Go to Networking → Firewalls → Create Firewall:
- Inbound: Allow SSH (port 22) from your IP only, HTTP (80) and HTTPS (443) if using Nginx
- Outbound: Allow all (OpenClaw needs to reach AI provider APIs and messaging services)
Tip
Cloud Firewalls filter traffic before it reaches your Droplet, providing better protection than UFW alone.
7
Enable backups and monitoring
Enable Droplet Backups (20% of Droplet cost, e.g. ~$2.40/mo for the {{price:digitalocean:Basic 2GB}} Droplet) from the Droplet settings for automatic weekly full-server backups.
Enable Monitoring (free) from the Droplet dashboard to track CPU, memory, disk, and network usage. Set up alerts for high memory usage — OpenClaw typically uses 300-800 MB RAM.
For volume snapshots on demand:
Enable Monitoring (free) from the Droplet dashboard to track CPU, memory, disk, and network usage. Set up alerts for high memory usage — OpenClaw typically uses 300-800 MB RAM.
For volume snapshots on demand:
# Take a manual snapshot from the DigitalOcean dashboard
# Snapshots → Take SnapshotTip
Set a memory alert at 80% to catch issues before the Droplet runs out of RAM.
Troubleshooting
1-Click App Droplet shows blank page on first visit
Wait 2-3 minutes after Droplet creation — the initialization script runs on first boot. SSH in and check status:
docker logs openclaw. If still blank, restart the container: docker compose -f /opt/openclaw/docker-compose.yml restart.Cannot SSH into the Droplet
Ensure your SSH key was added to your DigitalOcean account before creating the Droplet. If locked out, use the Recovery Console from the Droplet dashboard. Check that the Cloud Firewall allows SSH on port 22.
OpenClaw container exits with out-of-memory error
The {{price:digitalocean:Basic 1GB}}/mo Droplet (1 GB RAM) may be insufficient if running additional services. Upgrade to the {{price:digitalocean:Basic 2GB}}/mo plan (2 GB) from the Droplet dashboard — resize takes ~1 minute with no data loss. Add swap as a temporary fix:
fallocate -l 2G /swapfile && chmod 600 /swapfile && mkswap /swapfile && swapon /swapfile.SSL certificate not working with custom domain
Point your domain's A record to the Droplet IP. If using the 1-Click App, SSL auto-configures via Let's Encrypt. For manual setup, install Certbot:
apt install certbot python3-certbot-nginx -y && certbot --nginx -d yourdomain.com.Ready to get started with OpenClaw?
Put this tutorial into practice. Visit OpenClaw and follow the steps above.
Visit OpenClaw →