OpenClaw's Security Architecture
OpenClaw is designed with data sovereignty as a first principle. In self-hosted mode, you control where your data lives and who can access it.
Data Flow in Self-Hosted Mode
You (Telegram/WhatsApp/WebChat)
โ
Your VPS (OpenClaw)
โ
AI Model API (Claude/GPT/DeepSeek/etc.)
โ
Response
No data passes through OpenClaw's servers โ there are no OpenClaw servers in this chain. Your messages go directly from your device to your VPS, then to whichever AI model API you've configured.
What Data Is Stored Where
On Your VPS
- Conversation history (stored in your local database)
- Configuration files (API keys, Bot tokens, skill settings)
- Skill cache and execution logs
- All runtime data
With the AI Model Provider
The AI model API (Anthropic, OpenAI, DeepSeek, etc.) processes your message content. This is a necessary requirement of using cloud AI models โ the model needs to "see" the text to respond.
Each provider has its own data handling policy:
- Anthropic: By default, conversations are not used for training. Enterprise plans include zero-retention options.
- OpenAI: Opt-out from training data usage is available.
- DeepSeek: Domestic Chinese provider, conversations stored per their privacy policy.
- Ollama (local): Zero data transmitted โ model runs entirely on your machine.
With OpenClaw's Team
Nothing. OpenClaw is open-source software that runs on your own infrastructure. The OpenClaw project team has no servers in your data path and cannot access your data.
Maximum Privacy: Fully Offline with Ollama
For scenarios where data absolutely cannot leave your machine:
- Install Ollama locally:
curl -fsSL https://ollama.ai/install.sh | sh - Download a model:
ollama pull llama3.3:70b - Configure OpenClaw to use Ollama (see Supported Models guide)
- Run OpenClaw on the same machine (or local network)
In this configuration:
- Your messages never leave your local network
- No API keys needed, no external connections
- Complete data sovereignty
Securing Your OpenClaw Deployment
1. API Key Protection โ Secret Provider
Never store API keys in plain text in config files. Use OpenClaw's Secret Provider:
{
"secrets": {
"provider": "env",
"mapping": {
"ANTHROPIC_API_KEY": "ANTHROPIC_API_KEY",
"TELEGRAM_BOT_TOKEN": "TELEGRAM_BOT_TOKEN"
}
}
}
With this setup, sensitive values are loaded from environment variables at runtime โ never stored in the config file itself.
2. VPS Hardening
Basic security practices for your OpenClaw server:
# Disable password login, use SSH keys only
sudo sed -i 's/#PasswordAuthentication yes/PasswordAuthentication no/' /etc/ssh/sshd_config
sudo systemctl restart sshd
# Set up UFW firewall
sudo ufw allow 22/tcp # SSH
sudo ufw allow 18789/tcp # OpenClaw WebChat (restrict to your IP if possible)
sudo ufw enable
3. HTTPS for WebChat
If exposing WebChat externally, use a reverse proxy with TLS:
# Using Caddy (automatic HTTPS)
# In Caddyfile:
# your-domain.com {
# reverse_proxy localhost:18789
# }
4. Telegram Bot Security
Your Telegram Bot token is the authentication credential for your bot:
- Store it in environment variables, not in config files
- Never share it or commit it to version control
- Regenerate it via @BotFather if compromised
Conversation Data โ Retention and Deletion
OpenClaw stores conversation history in a local SQLite database by default.
View database location:
pnpm openclaw db path
Delete conversation history:
# Delete history older than 30 days
pnpm openclaw db clean --older-than 30d
# Delete all history
pnpm openclaw db clean --all
Disable history storage (conversations not stored locally):
{
"storage": {
"history": false
}
}
Skills Security
Community skills from ClawHub/SkillHub can execute code and make network requests. Follow these practices:
- Use curated skill sources: SkillHub's Top 50 list has been security audited
- Review skill permissions before installing: Check what resources the skill requests
- Prefer official skills: Skills with the โ verified badge
- Check install counts: Skills with 1,000+ installs are lower risk
See the ClawHub security section for detailed guidance.
FAQ
Can OpenClaw's team read my conversations?
No. OpenClaw is open-source software running on your own server. The OpenClaw team has no servers, no databases, and no ability to access your data.
Is Telegram a privacy risk with OpenClaw?
Telegram handles the message transport between your device and OpenClaw. Telegram's own privacy practices apply to messages in transit. For maximum privacy, use the WebChat interface (direct connection to your VPS) or a Telegram account with minimal personal info. Using Ollama (local models) eliminates any AI provider data exposure.
What happens to my data if I stop using OpenClaw?
Since all data lives on your VPS, you control its fate. Deleting the OpenClaw database removes your conversation history. Destroying the VPS removes all data permanently. There's no OpenClaw account or cloud data to worry about.
Does OpenClaw comply with GDPR?
OpenClaw itself (the software) doesn't process or store personal data on any shared infrastructure โ it runs entirely on your own systems. Compliance with GDPR or other regulations is your responsibility as the data controller. The AI model provider (Anthropic, OpenAI, etc.) you use also has its own compliance posture.