Skip to main content
πŸŽ“ Claude Code Masterclass Learn AI-assisted development on Udemy β€” plus the companion book on Leanpub & Amazon. Start Learning
Integrating OpenClaw with Home Assistant for Natural Language Home Control
AI

Integrating OpenClaw with Home Assistant for Natural...

Stop fumbling with dashboards. Connect OpenClaw to Home Assistant for natural language smart home control, automated routines, and proactive alerts.

LB
Luca Berton
Β· 1 min read

The Dashboard Problem

Home Assistant is incredible. But controlling it means opening an app, finding the right dashboard, tapping the right entity. What if you could just text your house?

β€œTurn off all the lights downstairs.” β€œWhat’s the temperature in the garage?” β€œSet the thermostat to 20Β°C when I leave.”

That’s what OpenClaw + Home Assistant gives you.

Architecture

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”     β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”     β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚  Discord /   │────▢│  OpenClaw    │────▢│  Home Assistant   β”‚
β”‚  WhatsApp    │◀────│  Gateway     │◀────│  REST API         β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜     β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜     β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                         β”‚                        β”‚
                    GPT-5-mini              Zigbee / Z-Wave
                    (reasoning)              (200+ devices)

Setting Up the Integration

Step 1: Create a Long-Lived Access Token in HA

Go to your Home Assistant profile β†’ Security β†’ Long-Lived Access Tokens β†’ Create Token.

Step 2: Configure OpenClaw

# openclaw.yaml
tools:
  home-assistant:
    type: rest-api
    baseUrl: http://homeassistant.local:8123
    headers:
      Authorization: "Bearer YOUR_HA_TOKEN"

Step 3: Create a Home Assistant Skill

# skills/home-assistant/SKILL.md
## Home Assistant Control

When the user asks to control home devices:
1. Query HA API for entity states: GET /api/states
2. Match natural language to entity IDs
3. Call services: POST /api/services/{domain}/{service}

Common mappings:
- "lights" β†’ light.* entities
- "temperature" β†’ sensor.*_temperature
- "thermostat" β†’ climate.* entities
- "lock/unlock" β†’ lock.* entities

Real-World Examples

Me: β€œGood night” OpenClaw: Turns off all lights, locks front door, sets thermostat to 18Β°C, arms alarm system.

Me: β€œIs the garage door open?” OpenClaw: Checks cover.garage_door state β†’ β€œYes, the garage door has been open for 2 hours. Want me to close it?”

Me: β€œToo warm in the office” OpenClaw: Checks sensor.office_temperature (26Β°C), turns on fan.office, adjusts climate.office to 22Β°C.

Automations That Talk Back

The real power is bidirectional. Home Assistant can trigger OpenClaw messages:

# HA automation: notify via OpenClaw when washing machine finishes
automation:
  - alias: "Washing Machine Done"
    trigger:
      - platform: state
        entity_id: sensor.washing_machine_power
        to: "0"
        for: "00:05:00"
    action:
      - service: rest_command.openclaw_notify
        data:
          message: "Washing machine finished 5 minutes ago"

OpenClaw receives this and forwards to your Discord/WhatsApp with context.

Privacy Advantage

Everything runs locally:

  • Home Assistant on a Pi or NUC
  • OpenClaw on a Pi
  • Zigbee coordinator (no cloud)
  • GPT-5-mini via Copilot Pro (only text queries leave your network, no device data)

No Google, no Amazon, no cloud dependency for device control.

Free 30-min AI & Cloud consultation

Book Now