Home Assistant Solar Automation — The Complete Setup Guide

📅 April 2026⏱️ 8 min read🏷️ Home Assistant · Solar

Having solar panels without automating them in Home Assistant is like having a sports car and only driving in first gear. The panels produce power whether you use it or not — the question is whether that power goes into your home loads, your battery, or out to the grid for little or no benefit.

This guide is based on a real 10kW SolaX X1-Hybrid-G4 installation in Pretoria with a 10.2 kWh battery, running Home Assistant with 869 entities. The automations below are tested and running daily.

The single most important concept

The best indicator of available solar excess is the battery charge rate (sensor.solax_battery_1_power_charge), not the PV production figure. When the battery is charging at 1,500W+, you have genuine excess you can redirect to other loads. PV production alone doesn't tell you this — you need to know what the rest of the house is consuming first.

Step 1 — Get Your Inverter into HA

Before you can automate anything, HA needs to see your inverter's data. The integration depends on your inverter brand:

Verify your integration is working by checking Developer Tools → States and searching for your inverter sensors. You should see battery SOC, PV power, and grid power updating in real time.

Step 2 — The Geyser Automation (Start Here)

An electric geyser is the single best target for solar automation. It's a pure resistive load (2–3kW), it doesn't care when it runs, and hot water stores the solar energy for hours. Here is the automation that runs on the real system:

automation:
  - alias: "Geyser on during solar excess"
    description: "Turn geyser on when battery charging strongly"
    trigger:
      - platform: numeric_state
        entity_id: sensor.solax_battery_1_power_charge
        above: 1000
        for: "00:05:00"
    condition:
      - condition: time
        after: "09:00:00"
        before: "15:30:00"
      - condition: numeric_state
        entity_id: sensor.solax_battery_soc
        above: 40
    action:
      - service: switch.turn_on
        entity_id: switch.geyser
        
  - alias: "Geyser off when solar drops"
    trigger:
      - platform: numeric_state
        entity_id: sensor.solax_battery_1_power_charge
        below: 200
        for: "00:03:00"
      - platform: numeric_state
        entity_id: sensor.solax_battery_soc
        below: 30
    action:
      - service: switch.turn_off
        entity_id: switch.geyser

The 5-minute delay on the trigger prevents the geyser from toggling on and off during brief cloud cover. The SOC condition ensures you don't drain the battery below a useful level just to heat water.

Step 3 — AC Tiered Solar Mode

Air conditioning is your biggest variable load and the most powerful tool for solar self-consumption. The approach that works best is a tiered system with three modes that shift automatically based on available power:

This runs through a HA choose action in a single automation, triggered every time the battery SOC or PV power changes significantly. The real-world effect is that during a good solar day, the house sits at 22–23°C for free. On a cloudy day it conserves battery for the evening.

Step 4 — Pool Pump and Other Deferrable Loads

Pool pumps are ideal solar loads — they need to run every day, the exact timing doesn't matter, and they're simple on/off devices. Schedule them to run during peak solar hours (10:00–16:00) with a battery SOC condition:

automation:
  - alias: "Pool pump solar window"
    trigger:
      - platform: time
        at: "10:00:00"
    condition:
      - condition: numeric_state
        entity_id: sensor.solax_battery_soc
        above: 50
    action:
      - service: switch.turn_on
        entity_id: switch.pool_pump
        
  - alias: "Pool pump off at 16:00"
    trigger:
      - platform: time
        at: "16:00:00"
    action:
      - service: switch.turn_off
        entity_id: switch.pool_pump

Step 5 — Daily Solar Summary Notification

A sunset notification that summarises the day's production keeps you connected to your system without having to open the dashboard every day. This is one of the most satisfying automations to have running:

automation:
  - alias: "Daily solar summary"
    trigger:
      - platform: sun
        event: sunset
    action:
      - service: notify.mobile_app_your_phone
        data:
          title: "☀️ Solar Summary"
          message: >
            Today: {{ states('sensor.solax_today_s_solar_energy') }} kWh produced.
            Grid import: {{ states('sensor.solax_today_s_import_energy') }} kWh.
            Battery: {{ states('sensor.solax_battery_soc') }}% charged.

Things to Watch Out For

Want automations tailored to your specific setup?

Our Home Assistant Solar Automation Planner generates personalised automation recommendations and YAML snippets based on your inverter type, battery size, and the loads you want to control.

🏠 Open the HA Planner