ClawKit LogoClawKit

Your First OpenClaw Config File

Skip the Learning Curve

Our Config Wizard generates production-ready configs in 30 seconds. No YAML knowledge required.

Generate Config Now

What is clawhub.json?

The clawhub.json file is your agent's brain. It tells OpenClaw:

  • Which LLM to use (OpenAI, DeepSeek, Claude)
  • Your API credentials
  • Agent behavior and capabilities
  • Plugin configurations

Minimal Example

Here's the simplest possible config:

{
  "llm": {
    "provider": "openai",
    "apiKey": "sk-...",
    "model": "gpt-4o"
  }
}

Recommended Config (Production-Ready)

For real-world use, add these fields:

{
  "llm": {
    "provider": "openai",
    "apiKey": "sk-...",
    "model": "gpt-4o",
    "temperature": 0.7,
    "maxTokens": 4000
  },
  "agent": {
    "name": "MyAssistant",
    "host": "127.0.0.1",
    "port": 3000,
    "logLevel": "info"
  },
  "skills": [
    "browser-use",
    "memory-core"
  ]
}

Using DeepSeek (10x Cheaper)

DeepSeek V3.2 offers GPT-4-level performance at 1/10th the cost:

{
  "llm": {
    "provider": "deepseek",
    "apiKey": "sk-...",
    "model": "deepseek-chat",
    "baseURL": "https://api.deepseek.com/v1"
  }
}

💡 Pro Tip: Use our Cost Estimator to compare pricing before committing.

Common Mistakes to Avoid

❌ Trailing Commas

JSON doesn't support trailing commas. Our Config Wizard handles this automatically.

❌ Windows Path Escaping

Use C:\\\\Users not C:\\Users. The wizard auto-fixes this.

❌ Hardcoded API Keys

Never commit API keys to Git. Use environment variables instead.

Best Practices

Use 127.0.0.1 instead of localhost

Avoids IPv6 issues in Node.js v18+

Set maxTokens to prevent runaway costs

Recommended: 4000 for most tasks

Enable logging in development

Set logLevel to "debug" for troubleshooting

Validate before deploying

Use Config Wizard to catch syntax errors

Next Steps


Last Updated: February 6, 2026 | Time to Create: 30 seconds (with Config Wizard) or 10 minutes (manual)

Need Help?

Try our automated tools to solve common issues instantly.