

A comprehensive guide for setting up your personal AI assistant on any Virtual Private Server.
By TONNIC AI Agency

© TONNIC AI Agency
Before you begin the installation process, make sure you have everything ready. Having these prerequisites in place will ensure a smooth setup experience.

© TONNIC AI Agency

The first step is establishing a secure connection to your VPS. You'll use SSH (Secure Shell) to access your server remotely.
ssh root@YOUR_SERVER_IPsudo adduser openclaw
sudo usermod -aG sudo openclaw
sudo su - openclaw
© TONNIC AI Agency
OpenClaw requires Node.js version 22 or newer to run properly. This step ensures you have the correct runtime environment installed on your server.
curl -fsSL https://deb.nodesource.com/setup_22.x | sudo -E bash -sudo apt-get install -y nodejsnode -vShould show v22.x.x or higher.

© TONNIC AI Agency
Now it's time to install OpenClaw itself. The official installer automates most of the setup process, making it quick and easy to get started.
curl -fsSL https://openclaw.ai/install.sh | bashopenclaw onboard --install-daemonThe wizard will guide you through the configuration process and set up everything automatically, including the system service and initial settings.

© TONNIC AI Agency
OpenClaw supports multiple AI providers, giving you flexibility in how you access AI capabilities. Choose the option that best fits your needs and budget.
Prerequisites: Install Claude Code CLI first
curl -fsSL https://claude.ai/install.sh | bashThen follow setup at code.claude.com/docs/en/setup
Then generate setup-token:
claude setup-token
openclaw models auth paste-token --provider anthropicFor direct API access:
openclaw models auth login --provider anthropicChatGPT/Codex subscription via OAuth:
openclaw onboard --auth-choice openai-codexOr run OAuth directly:
openclaw models auth login --provider openai-codexFor usage-based billing:
openclaw onboard --auth-choice openai-api-key
© TONNIC AI Agency
Once OpenClaw is installed and configured, you'll want to access the web dashboard to manage your assistant. This requires creating a secure SSH tunnel from your local computer to the server.
ssh -N -L 18789:127.0.0.1:18789 openclaw@YOUR_SERVER_IPhttp://127.0.0.1:18789/

© TONNIC AI Agency
To ensure OpenClaw runs continuously and starts automatically after server reboots, it needs to be configured as a system service. The onboard wizard sets this up automatically, but it's useful to know how to manage it.
sudo systemctl status openclaw-gateway.servicesudo systemctl start openclaw-gatewaysudo systemctl stop openclaw-gatewaysudo systemctl restart openclaw-gatewaysudo journalctl -u openclaw-gateway -f
© TONNIC AI Agency

If you encounter any issues during or after installation, OpenClaw provides several diagnostic commands to help identify and resolve problems.
openclaw status
openclaw doctor
openclaw logs --followPort in use → Another process is running on port 18789
Command not found → Add npm bin directory to PATH
Auth errors → Check your API key or token
Service won't start → Verify binary path in service file

© TONNIC AI Agency
After completing the installation, you'll have a powerful, self-hosted AI assistant at your fingertips. Here's what OpenClaw brings to your workflow:

© TONNIC AI Agency
Congratulations on installing OpenClaw! Now it's time to customize and enhance your AI assistant to fit your specific needs.
Set up WhatsApp, Telegram, and other messaging platforms
Explore available capabilities at clawhub.com
Edit AGENTS.md and SOUL.md files
Protect your configuration and data
Documentation
docs.openclaw.ai
GitHub Repository
github.com/openclaw/openclaw
Community Discord
discord.gg/openclaw

© TONNIC AI Agency
Understanding the unique strengths of agentic AI like OpenClaw versus traditional workflow automation tools is crucial for maximizing efficiency and innovation.

© TONNIC AI Agency
How to Install OpenClaw on a VPS