← Back to Articles

How to Install Clawd Bot

Neil Stephenson
Neil Stephenson

ClawdBot is your personal AI assistant that runs 24/7 on a cheap server. Message it on Telegram or WhatsApp, and Claude responds—with full context about who you are and what you're working on. This guide walks you through the complete setup, from spinning up a server to teaching your bot about yourself.

What You'll Need

  • Hetzner account — ~€4-5/month for a VPS
  • Claude subscription (Pro/Max) or an Anthropic API key
  • Telegram account — for the bot interface
  • Terminal app — Mac: Terminal / Windows: use WSL2

Part 1: Create Your Server

1.1 Set Up Hetzner VPS

  1. Go to hetzner.com/cloud
  2. Create account (requires credit card + ID verification)
  3. Click "Add Server"
  4. Choose:
    • Location: Nearest to you
    • Image: Ubuntu 24.04
    • Type: CX22 (4GB RAM) — ~€4/month
    • SSH Key: Add your public key (see below)
  5. Click "Create & Buy Now"
  6. Copy the IP address

1.2 Get Your SSH Key (Mac)

Bash
cat ~/.ssh/id_rsa.pub

If no key exists:

Bash
ssh-keygen -t ed25519 -C "your-email@example.com"
cat ~/.ssh/id_ed25519.pub

Paste the output into Hetzner when creating the server.

Note: Your public key is safe to share—it's like a padlock. The private key (without .pub) is what opens it and should never be shared.

Part 2: Connect & Secure Your Server

2.1 Connect via SSH

Bash
ssh root@YOUR-SERVER-IP

2.2 Update the System

Bash
apt update && apt upgrade -y

2.3 Create a Non-Root User

Bash
adduser YOUR-USERNAME

Set a password and press Enter through the prompts.

Bash
usermod -aG sudo YOUR-USERNAME

2.4 Enable SSH for New User

Bash
mkdir -p /home/YOUR-USERNAME/.ssh
cp ~/.ssh/authorized_keys /home/YOUR-USERNAME/.ssh/
chown -R YOUR-USERNAME:YOUR-USERNAME /home/YOUR-USERNAME/.ssh
chmod 700 /home/YOUR-USERNAME/.ssh
chmod 600 /home/YOUR-USERNAME/.ssh/authorized_keys

2.5 Switch to New User

Bash
su - YOUR-USERNAME

Part 3: Install Dependencies

3.1 Install Node.js 22+

Bash
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.3/install.sh | bash

Close and reopen terminal, or run:

Bash
source ~/.bashrc

Then:

Bash
nvm install 22
node --version

3.2 Enable pnpm

Bash
corepack enable pnpm

Part 4: Install ClawdBot

Option A: Quick Install (Recommended)

Bash
curl -fsSL https://clawd.bot/install.sh | bash

Option B: Manual Install

Bash
npm install -g clawdbot@latest

Verify Installation

Bash
clawdbot --version

Part 5: Run the Onboarding Wizard

Bash
clawdbot onboard --install-daemon

Wizard Choices:

  • Gateway: Local
  • Runtime: Node (required for WhatsApp/Telegram)
  • Auth: Choose your method (see Part 6)
  • Messaging: Telegram (recommended for beginners)
  • Install daemon: Yes

Part 6: Set Up Claude Max Authentication

6.1 On Your Mac (not VPS)

Install Claude CLI:

Bash
npm install -g @anthropic-ai/claude-code

Generate token:

Bash
claude setup-token

If already authenticated:

Bash
claude setup-token --force

Copy the token displayed.

6.2 On Your VPS

Bash
clawdbot models auth add
  • Choose: anthropic
  • Method: paste token
  • Paste your token

6.3 Restart

Bash
clawdbot daemon restart

Part 7: Set Up Telegram Bot

7.1 Create Bot with BotFather

  1. Open Telegram
  2. Search for @BotFather
  3. Send /newbot
  4. Give it a name (e.g., "My AI Assistant")
  5. Give it a username (must end in bot)
  6. Copy the token

7.2 Add Token to ClawdBot

Bash
clawdbot configure --section telegram

Paste your bot token when prompted.

Bash
clawdbot daemon restart

Part 8: Approve Yourself (Pairing)

8.1 Message Your Bot

Open Telegram, find your bot, send "Hello!"

(It won't respond yet—this is a security feature)

8.2 Approve the Pairing

Bash
clawdbot pairing list telegram

Copy the code shown, then:

Bash
clawdbot pairing approve telegram CODE

8.3 Test It!

Send another message—your bot should respond!

Part 9: Access the Dashboard

9.1 On Your Mac — Start SSH Tunnel

Bash
ssh -N -L 18789:127.0.0.1:18789 YOUR-USERNAME@YOUR-SERVER-IP

(Leave this running—it looks like it hangs, that's normal)

9.2 Open Dashboard

In your browser (use incognito if you have issues):

URL
http://localhost:18789/?token=YOUR-GATEWAY-TOKEN

The token was shown during onboarding. If you lost it:

Bash
cat ~/.clawdbot/clawdbot.json | grep token

Part 10: Teach Your Bot About You

Ask your bot in Telegram:

"I want you to interview me so you can be more useful. Ask me questions about my work, life, preferences, routines, goals—whatever you need to know to be a great assistant. Go one question at a time."

After the interview:

"Now save everything you've learned about me to your USER.md file"

Check what it knows:

"What do you currently know about me?"

Part 11: Optional Enhancements

Enable Web Search

Get a free API key from brave.com/search/api, then:

Bash
clawdbot configure --section web

Or just tell your bot:

"Set up Brave web search with this API key: YOUR-KEY"

Set Up Morning Briefings

Ask your bot:

"Set up a daily cron job at 7am that sends me a morning briefing with today's weather in YOUR-CITY, my top priorities, and the latest AI news."

Add ElevenLabs for Audio

Bash
clawdbot configure --section elevenlabs

Add WhatsApp

Bash
clawdbot channels login

Scan the QR code with WhatsApp → Settings → Linked Devices.

Useful Commands Reference

Commands
clawdbot health          # Check everything's working
clawdbot status          # Quick status overview
clawdbot daemon status   # Check if daemon is running
clawdbot daemon restart  # Restart the bot
clawdbot daemon stop     # Stop the bot
clawdbot logs --follow   # Watch live logs
clawdbot pairing list telegram  # See pending approvals
clawdbot channels login  # Link WhatsApp (QR scan)
clawdbot doctor          # Diagnose issues
clawdbot configure --section web  # Set up web search
clawdbot models auth add # Add/change AI authentication

Troubleshooting

"Address already in use" (SSH tunnel)

Kill what's using the port:

Bash
lsof -ti:18789 | xargs kill -9

If it keeps respawning:

Bash
launchctl unload ~/Library/LaunchAgents/com.clawdbot.gateway.plist

"unauthorized" in dashboard

Use the full URL with token, or try incognito mode.

"No API key found"

Run:

Bash
clawdbot models auth add

Bot not responding in Telegram

  1. Check it's running: clawdbot daemon status
  2. Check health: clawdbot health
  3. Make sure you approved pairing
  4. Check logs: clawdbot logs --tail 50

Need to check what user you're logged in as

Bash
whoami

Need to check you're on the VPS (not local)

Bash
hostname
Pro Tips:
  • Ask your bot to run commands for you—no need to SSH in for most things
  • Give your bot API keys directly—it can configure itself
  • Use voice notes—great for brain dumps on the go
  • Ask for suggestions: "What automations would you suggest based on what you know about me?"

Resources

Neil Stephenson

Written by Neil Stephenson

I build automation systems and AI tools, then share everything I learn. Follow along on YouTube or Twitter for more tips on working smarter.