Clone and deploy OpenClaw to a new VPS via SSH, installing the software and copying all ~/.openclaw data with optional credential updates.
Overview: Deploy OpenClaw to a new VPS using SSH and a non-interactive installer, then copy your ~/.opencl workspace and verify/update credentials.
SSH access to the new VPS: IP address, username, and password (or SSH key)
The new VPS runs a supported Linux distribution (verify with the official docs)
Ensure outbound connectivity on the new VPS (to fetch the installer)
Security: When prompted for passwords, avoid hardcoding them; prefer password prompts or SSH key-based auth.
ssh USER@VPS_IP
USER with the provided username and VPS_IP with the target IP.If auth uses an SSH key, ensure the private key is available and permissions are tightened (e.g., 600).
ssh USER@VPS_IP 'bash -c "$(curl -fsSL https://openclaw.ai/install.sh)" -- --no-onboard'
--no-onboard skips the interactive onboarding wizard.If the new VPS blocks curl or https://openclaw.ai, download the installer locally and scp/transfer it before running bash install.sh -- --no-onboard.
Source path (current environment): ~/.openclaw
Target directory on the new VPS: ~/.openclaw
Create a compressed archive, transfer it, and extract on the new VPS:
# Compress (on source)
cd ~ && tar czf openclaw-data.tar.gz --exclude='*.log' --exclude='cache' --exclude='node_modules/.cache' .openclaw
# Transfer
scp openclaw-data.tar.gz USER@VPS_IP:~/
# Extract (on new VPS)
ssh USER@VPS_IP 'rm -rf ~/.openclaw && tar xzf ~/openclaw-data.tar.gz -C ~/'
# Cleanup (optional, on both sides)
rm openclaw-data.tar.gz
ssh USER@VPS_IP 'rm ~/openclaw-data.tar.gz'
Notes and cautions:
*.log, cache, and node_modules/.cache to reduce archive size; adjust based on your directory layout.~/.openclaw directory:
~/.openclaw/config.* or environment files)Where to find credentials:
~/.openclaw/config or related config files for tokens or service identifiers.ssh USER@VPS_IP 'sudo systemctl restart openclaw || openclaw restart || echo "Restart manually per your system"'
ssh USER@VPS_IP 'sudo systemctl status openclaw').ssh USER@VPS_IP 'journalctl -u openclaw -n 50' or relevant log path).~/.openclaw.ZIP package — ready to use