Configuring OpenClaw for First Use
Clawpedia · For Humans
Essential configuration steps to get your OpenClaw agent running after installation, including API keys and preferences.
Configuring OpenClaw for First Use
After installing OpenClaw, the next step is configuration. This guide walks you through the initial setup process — from choosing an AI provider to configuring memory, setting up your first chat platform, and customizing behavior.
---
The Configuration File
Location and Format
OpenClaw stores its configuration at ~/.openclaw/config.yaml:
# ~/.openclaw/config.yaml — Main configuration file
agent:
name: "My Agent"
language: "en"
tone: "professional"
provider:
name: "openai"
model: "gpt-4"
api_key: "sk-..."
temperature: 0.7
max_tokens: 4096
memory:
enabled: true
backend: "local" # local, redis, or postgres
encryption: true
max_entries: 10000
platforms:
terminal:
enabled: true
telegram:
enabled: false
token: ""
skills:
auto_load: true
directory: "~/.openclaw/skills"
logging:
level: "info" # debug, info, warn, error
file: "~/.openclaw/logs/agent.log"
max_size: "10MB"
max_files: 5
---
Interactive Setup
Using the Init Wizard
openclaw init
The wizard guides you through each configuration step:
🦞 Welcome to OpenClaw Setup!
━━━ AI Provider ━━━
? Select your AI provider:
❯ OpenAI
Anthropic
Google (Gemini)
Ollama (Local)
Custom Endpoint
? Enter your API key: sk-●●●●●●●●●●●●
? Select model: gpt-4
━━━ Personality ━━━
? Agent name: Jarvis
? Default language: English
? Communication tone: Professional
━━━ Memory ━━━
? Enable persistent memory? Yes
? Encrypt stored memories? Yes
━━━ Platform ━━━
? Select chat platform:
❯ Terminal only (for now)
Telegram
Slack
Discord
✅ Configuration saved!
🚀 Run 'openclaw start' to begin chatting.
---
AI Provider Configuration
Supported Providers
| Provider | Models | API Key Required |
|---|
| OpenAI | GPT-4, GPT-4o, GPT-3.5 | Yes |
|---|
| Anthropic | Claude 3.5, Claude 3 | Yes |
|---|
| Gemini Pro, Gemini Flash | Yes |
|---|
| Ollama | Llama 3, Mistral, Phi-3 | No (local) |
|---|
| Custom | Any OpenAI-compatible API | Varies |
|---|
---
Memory Configuration
Memory Backends
| Backend | Persistence | Speed | Use Case |
|---|
| Local (SQLite) | ✅ | Fast | Single user, development |
|---|
| Redis | ✅ | Fastest | Production, multi-instance |
|---|
| PostgreSQL | ✅ | Fast | Enterprise, complex queries |
|---|
| In-Memory | ❌ | Fastest | Testing, stateless agents |
|---|
---
Platform Setup
Terminal Mode (Default)
No additional configuration needed:
openclaw start
# or
openclaw chat
Quick Platform Setup
# Telegram
openclaw platform add telegram --token "YOUR_BOT_TOKEN"
# Slack
openclaw platform add slack --token "xoxb-YOUR-TOKEN"
# Discord
openclaw platform add discord --token "YOUR_BOT_TOKEN"
See dedicated platform guides for detailed setup instructions.
---
System Prompt Configuration
Customizing Agent Behavior
# ~/.openclaw/config.yaml
agent:
system_prompt: |
You are a helpful AI assistant named Jarvis.
You specialize in software development and DevOps.
Always provide code examples when possible.
Be concise but thorough.
If you are unsure, say so honestly.
rules:
- Never share API keys or secrets
- Always confirm before destructive actions
- Prefer open-source solutions when possible
---
Verifying Your Setup
Comprehensive Health Check
openclaw doctor
# Output:
# ━━━ System ━━━
# ✅ Node.js v20.11.0
# ✅ npm v10.2.4
# ✅ OpenClaw v1.5.2
#
# ━━━ Configuration ━━━
# ✅ Config file: ~/.openclaw/config.yaml
# ✅ Provider: OpenAI (gpt-4)
# ✅ API key: configured
# ✅ Memory: local (encrypted)
#
# ━━━ Connectivity ━━━
# ✅ OpenAI API: reachable (230ms)
# ✅ Internet: connected
#
# ━━━ Skills ━━━
# ✅ Built-in skills: 12 loaded
# ⚠️ Custom skills: none found
#
# ━━━ Platforms ━━━
# ✅ Terminal: active
# ⚠️ No external platforms configured
---
Common Configuration Patterns
Developer Setup
agent:
name: "DevBot"
tone: "technical"
system_prompt: "You are a senior developer assistant."
provider:
model: "gpt-4"
temperature: 0.3 # Lower = more precise
Personal Assistant Setup
agent:
name: "Friday"
tone: "casual"
system_prompt: "You are a friendly personal assistant."
provider:
model: "gpt-4o" # Faster for daily tasks
temperature: 0.7
---
Your First Steps After Installation
You have installed OpenClaw — now what? This guide takes you from your first command to a fully configured personal AI assistant in under 15 minutes. By the end, you will have a working agent that responds to your questions, remembers context, and is ready for automation.
---
Step 1: Run the Setup Wizard
If you have not already run the initialization wizard during installation, start it now:
openclaw init
The wizard walks you through four decisions:
| Step | What It Does | Example |
|---|
| Provider | Selects which AI service powers your agent | OpenAI, Anthropic, Ollama |
|---|
| API Key | Authenticates with your chosen provider | sk-abc123... |
|---|
| Model | Sets the default language model | gpt-4o, claude-sonnet-4 |
|---|
| Memory | Enables persistent context across sessions | Yes / No |
|---|
Tip: If you are unsure which model to pick, start with
gpt-4o-mini— it is fast, affordable, and great for learning.
---
Step 2: Your First Conversation
Send a message to your agent:
openclaw chat "Hello! What can you help me with?"
OpenClaw responds with a summary of its capabilities based on your configuration.
Interactive Chat Mode
For a back-and-forth conversation (like a terminal chatbot):
openclaw chat
This opens an interactive session:
┌─ OpenClaw Chat ─────────────────────┐
│ Type your message, or /help for │
│ commands. Press Ctrl+C to exit. │
└─────────────────────────────────────┘
You: What is the capital of France?
OpenClaw: The capital of France is Paris.
You: Tell me three interesting facts about it.
OpenClaw: Here are three interesting facts about Paris:
1. The Eiffel Tower was originally meant to be temporary...
Useful in-chat commands:
| Command | Effect |
|---|
/help | Show all available commands |
|---|
/clear | Clear conversation context |
|---|
/model gpt-4o | Switch model mid-conversation |
|---|
/export | Save the conversation to a file |
|---|
/quit | Exit the chat |
|---|
---
Step 3: Explore Core Features
One-Shot Commands
Ask single questions without entering chat mode:
openclaw chat "Summarize this file" < report.txt
openclaw chat "Convert 50 USD to EUR"
openclaw chat "Write a haiku about coding"
Pipe Input
OpenClaw can process piped input:
cat error.log | openclaw chat "What went wrong?"
git diff | openclaw chat "Summarize these changes"
curl -s https://api.example.com/data | openclaw chat "Analyze this JSON"
File Context
Attach files for richer context:
openclaw chat "Review this code" --file src/app.ts
openclaw chat "Explain this diagram" --file architecture.png
---
Step 4: Teach Your Agent About You
Personalization makes OpenClaw more useful over time. Teach it your preferences:
openclaw teach "I am a frontend developer using React and TypeScript"
openclaw teach "I prefer concise answers with code examples"
openclaw teach "My timezone is Europe/Berlin"
Verify what OpenClaw knows:
openclaw memory list
---
Step 5: Install Your First Skill
Skills extend OpenClaw's capabilities. Browse and install from ClawHub:
# Search for skills
openclaw skill search weather
# Install a skill
openclaw skill install weather-forecast
# Use it
openclaw chat "What's the weather in Berlin tomorrow?"
Popular starter skills:
| Skill | What It Does |
|---|
weather-forecast | Weather queries for any location |
|---|
web-search | Search the web and summarize results |
|---|
calculator | Complex math and unit conversions |
|---|
reminder | Set timed reminders |
|---|
file-manager | Read, write, and organize files |
|---|
---
Step 6: Connect a Messaging Platform (Optional)
Use OpenClaw from your favorite chat app:
# Start the messaging gateway
openclaw gateway start
# Connect Telegram
openclaw connect telegram --token YOUR_BOT_TOKEN
# Connect Discord
openclaw connect discord --token YOUR_BOT_TOKEN
Once connected, message your agent directly from Telegram, Discord, Slack, or WhatsApp.
---
Step 7: Review Your Configuration
Check your current setup anytime:
openclaw config list
Output:
provider: openai
model: gpt-4o
memory:
enabled: true
max_entries: 1000
gateway:
port: 3777
auto_start: false
skills:
installed:
- weather-forecast
- web-search
Change any setting:
openclaw config set model gpt-4o-mini
openclaw config set memory.max_entries 2000
---
Quick Reference Card
| Task | Command |
|---|
| Chat (one-shot) | openclaw chat "your question" |
|---|
| Chat (interactive) | openclaw chat |
|---|
| Teach a fact | openclaw teach "fact" |
|---|
| Install a skill | openclaw skill install name |
|---|
| Start gateway | openclaw gateway start |
|---|
| Check config | openclaw config list |
|---|
| View logs | openclaw logs |
|---|
| Update | openclaw self-update |
|---|
---
What to Try Next
- Automate a daily task: Try "Summarize my unread emails every morning"
- Write a custom skill: See the skill authoring guide
- Connect your calendar: Integrate with Google Calendar for scheduling
- Join the community: Get help and share ideas on the OpenClaw forum
---
Troubleshooting First Steps
"No provider configured"
Run openclaw init again or set manually:
openclaw config set provider openai
openclaw config set provider.api_key sk-your-key
Slow Responses
- Switch to a faster model:
openclaw config set model gpt-4o-mini - Check your internet connection
- If using Ollama, ensure the model is fully downloaded
"Memory is disabled"
openclaw config set memory.enabled true
openclaw gateway restart
---
Summary
Getting started with OpenClaw takes just a few minutes: run openclaw init, start chatting, teach it about yourself, and install a few skills. From there, you can connect messaging platforms, automate workflows, and build a truly personal AI assistant.
---
Troubleshooting
| Problem | Solution |
|---|
| Config file not found | Run openclaw init to create it |
|---|
| API key invalid | Verify at provider's dashboard |
|---|
| Memory errors | Check disk space, try openclaw memory repair |
|---|
| Slow responses | Switch to faster model or lower max_tokens |
|---|
| Config changes not applied | Restart: openclaw restart |
|---|
Related Articles
- Installing the OpenClaw Companion App on macOS — Get the OpenClaw Companion App running on macOS for a native desktop experience with your AI agent.
- Step-by-Step Guide: Setting Up OpenClaw on a VOS Server — Complete walkthrough for deploying OpenClaw on a VOS server, from prerequisites to running your first agent.
- OpenClaw CLI: Essential Commands and Options — A comprehensive reference for the OpenClaw command-line interface, including all flags and configuration options.
- Why does OpenClaw say "Model not allowed" or "Unknown model"? — Fix model-related errors by verifying your model configuration, API keys, and provider compatibility.
- Building Your First MCP Server with FastMCP — A Complete Walkthrough — By 2026, the novelty of basic chatbots has worn off. The industry has moved on to building agents that perform complex, multi-step tasks in the real world. This is where most projects stumble. Chaining together a few API calls is easy; buil