What You'll Build
By the end of this guide, you'll have:
- ✅ A running OpenClaw instance on your machine
- ✅ Your first AI agent executing commands via natural language
- ✅ Automated web browsing, file operations, and API calls
- ✅ Scheduled tasks running without your intervention
- ✅ Integration with messaging platforms (Telegram, Discord, Slack)
Time required: 30 minutes
Cost: $0 (open source)
Technical level: Intermediate (basic CLI familiarity)
Prerequisites Checklist
Before we start, ensure you have:
- Node.js 18+ installed (
node --versionto check) - Git installed (
git --versionto check) - A code editor (VS Code recommended)
- An OpenAI API key or OpenRouter key (for model access)
- 30 minutes of uninterrupted focus
Step 1: Install OpenClaw (5 minutes)
OpenClaw can be installed globally via npm or run with npx. We recommend global installation for regular use.
Option A: Global Installation (Recommended)
# Install globally
npm install -g openclaw
# Verify installation
openclaw --version
Initialize Your Workspace
# Create your workspace directory
mkdir ~/openclaw-workspace
cd ~/openclaw-workspace
# Initialize OpenClaw configuration
openclaw init
This creates the essential configuration files: config.yaml, .env, workspace/, and skills/.
Step 2: Configure Your AI Model (5 minutes)
Edit your .env file and add your API keys:
# OpenRouter (more models, better pricing)
OPENROUTER_API_KEY=sk-or-v1-your-openrouter-key-here
Edit config.yaml to set your model preferences:
model:
default: openrouter/anthropic/claude-3.5-sonnet
fast: openrouter/meta-llama/llama-3.3-70b
Step 3: Install Essential Skills (5 minutes)
Skills are OpenClaw's superpower. Install the essentials:
# Web browsing and automation
openclaw skills add browser
# Web search capabilities
openclaw skills add web-search
# Messaging integrations
openclaw skills add telegram
Step 4: Test Your First Agent (5 minutes)
Start OpenClaw in interactive mode:
openclaw chat
Try a natural language request:
Search for the latest news about AI automation and save a summary to ai-news.txt
Watch as OpenClaw uses web search, reads content, and creates a file automatically.
Step 5: Create Your First Automation
Let's build a daily market research bot. Create market-research.js:
#!/usr/bin/env node
const { OpenClaw } = require('openclaw');
async function main() {
const claw = new OpenClaw();
console.log('🔍 Starting market research...');
// Search for trending AI/tech topics
const results = await claw.tools.web_search({
query: 'AI startup funding news',
count: 5
});
// Save summary
await claw.tools.write_file({
path: './daily-brief.md',
content: JSON.stringify(results, null, 2)
});
console.log('✅ Report saved');
}
main().catch(console.error);
Step 6: Schedule Automated Execution
Add a daily cron job:
openclaw cron add \
--name "daily-market-research" \
--schedule "0 8 * * *" \
--command "node market-research.js"
Step 7: Add Telegram Notifications
Get reports delivered to your phone:
- Message @BotFather on Telegram to create a bot
- Save your bot token and chat ID
- Add to your .env: TELEGRAM_BOT_TOKEN and TELEGRAM_CHAT_ID
Your agent can now send messages with:
await claw.tools.telegram.send({
chat_id: process.env.TELEGRAM_CHAT_ID,
message: '📊 Daily brief ready!'
});
Security Best Practices
- ⚠️ Never commit .env files — Add to .gitignore
- ⚠️ Use restricted API keys — Create limited-scope keys
- ⚠️ Review agent actions — Start with DRY_RUN=true
- ⚠️ Monitor logs — Check ~/openclaw-workspace/logs/
Next Steps: Scale Your Automation
Week 1: Master the Basics
- Build 3 more simple agents for daily tasks
- Set up 5 scheduled automations
- Connect Telegram notifications
Week 2: Integrate Everything
- Connect to your calendar (Google/Outlook)
- Automate email responses with AI
- Build a personal knowledge base agent
The Bottom Line
OpenClaw transforms AI from a chat interface into an action layer for your digital life. While others are prompting ChatGPT and copying outputs, you'll have agents running 24/7, handling research, monitoring, and execution.
The builders who master agentic automation in 2026 will operate at 10x the speed of everyone else.
Start building.