How to Run Your Own Self‑Hosted AI Assistant with OpenClaw – Full Guide

OpenClaw is an open‑source, self‑hosted AI assistant that lets you keep all data locally while chatting through familiar tools like Telegram and Discord, switch freely among Claude, GPT and Gemini models, extend functionality with a rich toolset, and control devices via a node system, all orchestrated by a central Gateway.

Top Architecture Tech Stack
Top Architecture Tech Stack
Top Architecture Tech Stack
How to Run Your Own Self‑Hosted AI Assistant with OpenClaw – Full Guide

Overview

OpenClaw is an open‑source, self‑hosted personal AI assistant platform. It runs as a daemon (Gateway) on a local machine and connects AI models (Claude, OpenAI GPT, Gemini, Bedrock) to messaging channels and tools while keeping all data locally. The project is MIT‑licensed.

OpenClaw guide
OpenClaw guide

Core capabilities

Multi‑channel access

Telegram – Bot API via grammY (private chat + groups)

Discord – discord.js (private chat + server channels)

WhatsApp – Baileys Web protocol

iMessage – macOS imsg CLI

Mattermost – plugin integration

Slack, Signal, Microsoft Teams – optional plugins

WebChat – local browser chat UI

Model switching

Supports Anthropic Claude (Opus, Sonnet, Haiku), OpenAI GPT‑4o, GPT‑5, o1, Google Gemini, and additional models via Amazon Bedrock. Switching is performed with a slash command:

/model opus    # Claude Opus
/model sonnet  # Claude Sonnet
/model gpt-4o  # GPT‑4o

Built‑in toolset

browser

– AI can browse and interact with web pages. canvas – visual workspace controlled by the AI. cron – scheduler for one‑off or recurring tasks. webhooks – real‑time integration with external services (GitHub, Gmail, etc.). memory_search – natural‑language search over past conversations and stored data. message – send, edit, react to messages across channels. nodes – remote control of iOS/Android/macOS devices. exec – shell command execution with PTY support and approval workflow. read/write/edit – direct file‑system manipulation. web_search / web_fetch – web search and content extraction. tts – text‑to‑speech conversion.

Node system

Devices running the OpenClaw node app (iPhone, Android, macOS) can be paired via a WebSocket gateway. Node capabilities include:

Camera snapshot (front/rear)

Video recording

Screen capture

Push notifications (system, floating, auto)

GPS location queries (coarse, balanced, precise)

SMS sending from Android nodes

Shell command execution on the host

Skill system & ClawHub marketplace

Skills are small packages that extend functionality. They can be installed from the community‑driven ClawHub registry using npm:

npx clawhub@latest install caldav-calendar   # calendar integration
npx clawhub@latest install trello            # Trello board management

Skills are loaded in the following priority order: <workspace>/skills/, ~/.openclaw/skills/, then built‑in defaults.

Multi‑agent system

Independent workspaces per agent.

Docker‑based sandbox isolation.

Per‑agent tool restrictions (e.g., disable exec, allow only read).

Binding rules map specific channels to specific agents.

Sub‑agents can be spawned for background tasks.

Gateway architecture

The Gateway is a persistent daemon listening on ws://127.0.0.1:18789. It manages channel connections, routes tool calls, bridges AI coding agents (Pi) via RPC, handles session routing, hosts the Canvas UI, and provides a web dashboard for configuration.

Local loopback binding by default.

One gateway per host to avoid session conflicts.

Token‑based authentication for remote access (recommended via Tailscale/VPN or SSH tunnel).

Cross‑platform support

macOS – native app with menu‑bar and voice activation.

iOS – node app with Canvas UI.

Android – node app with Canvas, chat, and camera.

Windows – native client (also works under WSL2).

Linux – native client and server deployment.

Project components

OpenClaw Gateway – core runtime.

Pi – coding‑agent engine communicating with the Gateway.

ClawHub – skill registry.

OpenClaw.app – macOS desktop client.

OpenClaw iOS / Android – node applications.

Source code: github.com/openclaw/openclaw Documentation:

docs.openclaw.ai

Claude Code integration (optional)

For software‑development‑focused automation, Anthropic’s Claude Code (Opus 4.6) can be accessed through OpenClaw’s model routing. It provides a terminal‑based AI that can read/modify code, run tests, fix bugs, and perform Git operations autonomously. Access requires an Anthropic API key and a paid subscription (Claude Pro $20/mo, Claude Max $200/mo). Alternative API providers such as Code80 can be used where official access is limited.

Security considerations

Node pairing requires explicit approval.

Gateway binds to localhost unless token authentication is configured.

Shell execution ( exec) is gated by an approval workflow.

Remote access must use token‑based authentication.

Typical use cases

Privacy‑focused personal assistants that keep conversation data locally.

Automation of notifications, scheduling, and device control via chat commands.

Multi‑messenger AI access without installing separate apps.

Team environments where different agents handle distinct roles.

Automationprivacyopen-sourceAI AssistantOpenClawTelegram IntegrationSelf‑hosted AI
Top Architecture Tech Stack
Written by

Top Architecture Tech Stack

Sharing Java and Python tech insights, with occasional practical development tool tips.

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.