How to install OpenClaw on a VPS: step-by-step guide
A complete walkthrough for installing OpenClaw on your own VPS. From choosing a server to configuring AI models and messaging channels.
Prerequisites
Before installing OpenClaw, you'll need:
- A VPS running Ubuntu 22.04 or newer (Debian 12+ also works)
- At least 2 GB RAM and 20 GB storage
- SSH access to your server
- An AI API key (OpenAI, Anthropic, or OpenRouter)
Recommended VPS providers
For the best value, we recommend:
- Hetzner CX22 — EUR 4.35/month, 2 GB RAM, excellent network (our top pick)
- DigitalOcean — USD 12/month, 2 GB Droplet, great documentation
- Contabo — EUR 5/month, 4 GB RAM, budget-friendly
Step 1: connect to your server
Open your terminal and SSH into your VPS:
ssh root@YOUR_SERVER_IP
First thing, update your system:
apt update && apt upgrade -y
Step 2: run the k-claw installer
With a k-claw subscription, installation is a single command:
curl -fsSL https://claw.krokanti.com/install | bash
The installer will:
- Ask for your license key
- Validate it against the k-claw API
- Establish a secure SSE connection
- Walk you through configuration questions
- Install everything automatically
Step 3: configure your agent
The installer asks you about:
- AI model — Claude Sonnet, GPT-4o, DeepSeek, or GLM Flash
- API key — Your OpenRouter key for model access
- Messaging channel — Telegram, WhatsApp, Discord, or Slack
- Bot token — Your platform-specific bot credentials
Step 4: verify installation
After installation completes, verify everything is running:
systemctl status kclaw-*
Then test by sending a message to your bot on your chosen messaging platform.
What gets installed
The k-claw installer sets up:
- Node.js 22 runtime
- OpenClaw agent framework
- UFW firewall with SSH-only access
- Fail2Ban for brute-force protection
- Dedicated system user with restricted permissions
- Systemd service for automatic startup
Troubleshooting
If something goes wrong during installation, the k-claw dashboard shows real-time status of your installation. Common issues and solutions are covered in our courses.
Pick your VPS — we handle everything else.
k-claw installs OpenClaw on any Ubuntu/Debian server. Security hardening, service setup, and configuration — all automatic.
Set up my serverRelated articles
What is a personal AI agent? A complete guide for 2026
Learn what personal AI agents are, how they work, and why self-hosting gives you privacy, control, and unlimited customization compared to cloud-based assistants.
Best AI models for personal agents in 2026: cost vs performance
Compare GPT-4o, Claude Sonnet 4, DeepSeek V3, and local models for personal AI agents. We break down costs, capabilities, and when to use each.