Installing OpenClaw on a VPS requires a Linux server (Ubuntu 22.04 or 24.04 LTS recommended), SSH access, an AI model API key or Ollama for local inference, and credentials for at least one messaging platform. The official page documents a three-step process: choose plan, SSH into the onboarding wizard, and launch via terminal or the Control UI over an SSH tunnel. Manual install from the OpenClaw GitHub repository follows a similar flow — verify all commands from the repository README before running.
The Pre-Installed Option: Contabo OpenClaw Hosting
The fastest path to a running OpenClaw instance is a Contabo VPS plan with OpenClaw pre-installed. The official page confirms the three-step process:
- Choose a plan at contabo.com/en/openclaw-hosting/ — plans are labelled by use case (Personal Use, Power User, Team Deployment, Enterprise Scale). See the page for current pricing.
- Once the server is deployed, connect via SSH and run the onboarding wizard. Add your AI provider API keys (they are encrypted on setup), connect your messaging apps, and configure your preferences.
- Launch the terminal interface to interact with your assistant directly, or access the Control UI securely via SSH tunnel.
Contabo provides full technical support for the VPS infrastructure and the initial 1-click installation. Configuring, maintaining, and troubleshooting OpenClaw itself is the user’s responsibility. For app-level questions, refer to the OpenClaw documentation and GitHub community.
Manual Install: Prerequisites
If you prefer to install from the OpenClaw GitHub repository, gather these before starting:
- A Linux VPS — Ubuntu 22.04 LTS or 24.04 LTS recommended. Verify supported distributions from the OpenClaw GitHub README.
- SSH root or sudo access.
- Sufficient RAM for your planned AI model (see the RAM requirements section below).
- An AI model API key — OpenAI, Anthropic, or Google — or plan to use Ollama for local inference at no API cost.
- Messaging platform credentials: bot token or webhook URL for your chosen app.
- Optionally: a domain name to point at your VPS for a clean gateway URL.
Step 1: Prepare Your VPS
- Update the system:
sudo apt update && sudo apt upgrade -y - Create a non-root user for running OpenClaw:
adduser openclaw-user
usermod -aG sudo openclaw-user
Switch to this user — never run OpenClaw as root. - Configure UFW firewall:
sudo ufw default deny incoming
sudo ufw allow OpenSSH
sudo ufw enable - Activate the Contabo network-level Firewall before opening any other ports: new.contabo.com → Network Services → Firewall → block all inbound by default.
Step 2: Install OpenClaw
Verify the exact commands from the OpenClaw GitHub repository before running — the project is actively developed and install steps change between releases. General flow:
- Clone the repository (verify current URL from official OpenClaw documentation):
git clone https://github.com/[openclaw-repo] openclaw
cd openclaw - Install the required runtime — check the README for whether Node.js or Python is required for your version:
# Node.js example:
npm install - Copy the environment file template and configure it:
cp .env.example .env
nano .env
Add your AI model API key and gateway credentials. Save the file. - Follow any additional setup steps in the repository README.
Step 3: Connect Your Messaging App
The following messaging platforms are confirmed on the official page: WhatsApp, Telegram, Discord, Slack, Signal, iMessage, Microsoft Teams.
Telegram
Create a bot via @BotFather on Telegram: send /newbot, follow the prompts, copy the bot token. Add the token to your .env file — verify the exact key name from OpenClaw documentation.
Discord
Create a Discord application at discord.com/developers/applications, add a Bot, copy the token and add to .env. Generate an OAuth2 invite URL with the bot scope and required permissions, then invite the bot to your server. Verify required permissions from OpenClaw docs.
Slack
Create a Slack app at api.slack.com/apps. Use the app manifest method if available. Copy the bot token and signing secret to .env. Verify the current Slack manifest template from OpenClaw documentation.
WhatsApp integration method varies — verify the current supported approach from the OpenClaw GitHub repository before proceeding, as platform policy changes affect available methods.
Step 4: Configure Your AI Model
Add credentials for your chosen AI model to .env. All four providers below are confirmed on the official page:
| AI Provider | Environment Variable | Where to Get the Key |
|---|---|---|
| Anthropic Claude | ANTHROPIC_API_KEY (verify key name from docs) | console.anthropic.com/settings/keys |
| OpenAI GPT | OPENAI_API_KEY (verify key name from docs) | platform.openai.com/api-keys |
| Google Gemini | GEMINI_API_KEY (verify key name from docs) | aistudio.google.com/app/apikey |
| Ollama (local) | OLLAMA_BASE_URL, typically http://localhost:11434 | Install Ollama separately — see below |
Important note from the official FAQ: ‘you will pay per token — be sure to keep an eye on token usage as these costs can add up fast with an autonomous agent like OpenClaw.’ Ollama eliminates this cost by running models locally on the VPS.
Setting Up Ollama for Local Inference
- Install Ollama on the same VPS:
curl -fsSL https://ollama.com/install.sh | sh - Pull a model:
ollama pull llama3 - Set the Ollama endpoint in .env:
OLLAMA_BASE_URL=http://localhost:11434
Verify the exact key name from OpenClaw docs.
RAM requirements for local inference: approximately 8 GB for a 7B parameter model, 16 GB for a 13B model. See contabo.com/en/openclaw-hosting/ for plan RAM specs.
Step 5: Set Up Your Domain and SSL
The official FAQ confirms: ‘Yes. Point your domain to your VPS IP address and configure SSL with Let’s Encrypt for secure access to your OpenClaw instance.’
- Point your domain’s A record to your VPS IP at your registrar.
- Install certbot:
sudo apt install certbot - Obtain an SSL certificate:
sudo certbot certonly –standalone -d yourdomain.com - Configure OpenClaw to use the certificate — verify the config method from OpenClaw docs.
- Open the gateway port in UFW (replace 3000 with your actual port):
sudo ufw allow 3000
Also add the rule in the Contabo Firewall at new.contabo.com.
Step 6: Start OpenClaw and Test
Run OpenClaw as a systemd service so it restarts automatically after a server reboot. Create a service file at /etc/systemd/system/openclaw.service (verify the correct ExecStart command and working directory from OpenClaw docs):
[Unit]
Description=OpenClaw AI Agent
After=network.target
[Service]
Type=simple
User=openclaw-user
WorkingDirectory=/home/openclaw-user/openclaw
ExecStart=/usr/bin/node index.js
Restart=on-failure
RestartSec=5
[Install]
WantedBy=multi-user.target- Enable and start:
sudo systemctl enable openclaw
sudo systemctl start openclaw - Check status:
sudo systemctl status openclaw - Send a test message from your messaging app — a response confirms the full stack is working.
Common issues:
- No response from messaging app: check the gateway port is open in both UFW and the Contabo Firewall.
- API key error: verify the key is correctly set in .env with no extra spaces or quotes.
- Ollama model not loading: run free -h to check available RAM; pull a smaller model if needed.
FAQ: Installing OpenClaw on a VPS
Update your system, clone the OpenClaw repository from GitHub, install the required runtime (Node.js or Python — check the current README), configure .env with your AI model API key and messaging credentials, and start it as a systemd service. Alternatively, use a Contabo pre-installed plan to skip manual setup entirely. Always verify install commands from the OpenClaw GitHub repository before running.
With cloud AI providers (OpenAI, Anthropic, Google), OpenClaw itself needs minimal RAM — AI processing happens on the provider’s servers, not on your VPS. With Ollama for local inference: approximately 8 GB for a 7B model, 16 GB for a 13B model. See contabo.com/en/openclaw-hosting/ for plan RAM specifications.
Yes — using Ollama for local inference. Install Ollama on the same VPS, pull a model (ollama pull llama3), configure OpenClaw to use the local Ollama endpoint. No API costs, no data leaving your server beyond your own VPS. Tradeoff: local models require more RAM and quality may vary compared to GPT-4 or Claude.
Confirmed from official FAQ: Contabo provides technical support for the VPS infrastructure — server hardware, network, and the initial 1-click OpenClaw installation. Once installed, configuring, maintaining, and troubleshooting the application is the user’s responsibility. For OpenClaw-specific questions, refer to the official documentation and the GitHub community.