Home Assistant Solar Integration Guide: Turn Inverter Data Into Something Actually Useful
Meta Description: Learn how to integrate your solar inverter with Home Assistant using Solar Assistant, MQTT, Modbus, and smart automations. Includes dashboards, energy setup, and real-world examples.
Target Keywords: solar inverter Home Assistant integration, Solar Assistant MQTT Home Assistant, Home Assistant energy dashboard solar battery, inverter Modbus Home Assistant, solar charging automation Home Assistant
A lot of solar monitoring apps are fine if all you want is a pretty graph and a vague sense that your panels are doing panel things.
I wanted more than that.
I wanted to know when my battery hit absorption, when grid charging kicked in, whether my inverter was honoring time-of-use settings, how much load I was actually carrying overnight, and when it made sense to automate things like EV charging, water heating, or load shedding.
That is where Home Assistant solar integration stops being a nerd hobby and starts being genuinely useful.
I have run hybrid inverter setups with LuxPower gear, LiFePO4 batteries, Solar Assistant, MQTT, and Home Assistant long enough to have strong opinions about what works, what breaks, and what ends up being a complete waste of time. This guide is the version I wish I could hand people before they spend a weekend reinventing bad telemetry.
The short version: get reliable inverter data into Home Assistant first, then build dashboards, then build automations. Doing it in the opposite order is how you end up with a beautiful dashboard full of lies.
Table of Contents
- What Home Assistant Can Actually Do for Solar
- The Three Main Integration Methods
- My Recommended Architecture
- What Hardware and Software You Need
- Method 1: Solar Assistant + MQTT
- Method 2: Direct Modbus Integration
- Method 3: Vendor Cloud Integrations
- Setting Up the Home Assistant Energy Dashboard
- Building a Solar Dashboard That Tells the Truth
- My Favorite Solar Automations
- Real Example: Battery-Aware Load Control
- Common Problems and Fixes
- Recommended Gear and Final Thoughts
What Home Assistant Can Actually Do for Solar
If all you need is “battery is at 82%” and “solar made 24 kWh today,” your inverter app may be enough.
But Home Assistant becomes worth the effort when you want to:
- combine solar, battery, grid, and load data in one place
- trigger automations based on state of charge, PV production, or utility rates
- track energy imports and exports over time
- decide when to run discretionary loads
- alert on weird behavior like unexpected bypass mode, no overnight charging, or battery not reaching float
- build dashboards for daily operation instead of digging through vendor apps
That last part matters more than people think. A lot of stock inverter portals feel like they were designed by a committee that hates humans.
Home Assistant lets you build the dashboard you need.
The Three Main Integration Methods
There are three realistic ways to get solar inverter data into Home Assistant.
1. Solar Assistant via MQTT
This is my preferred path for most DIY systems.
Why I like it:
- very little custom work
- supports a huge range of inverters
- provides local data without vendor cloud nonsense
- exposes a clean stream of battery, PV, grid, and load values
- works especially well with LuxPower and other hybrid inverter ecosystems
If your inverter is supported by Solar Assistant, this is usually the fastest path to useful data.
2. Direct Modbus from Home Assistant
This works well if:
- your inverter exposes Modbus TCP or RS485 registers cleanly
- you are comfortable reading docs and register maps
- you do not want another box in the chain
This path is flexible, but it can also be fussy. Register names vary, scaling is annoying, and vendor documentation is often written like it lost a bet.
3. Vendor Cloud Integration
This is the path I recommend the least.
It can be useful when:
- there is no good local integration path
- you only need read-only visibility
- you are okay with outages or delayed telemetry
But cloud integrations are often slow, rate-limited, incomplete, and one API change away from turning into decorative trash.
My Recommended Architecture
For a DIY hybrid setup, this is the stack I recommend:
Inverter/Battery -> Solar Assistant -> MQTT -> Home Assistant
That gives you:
- local-first data
- near real-time updates
- less custom polling logic
- easy expansion into Node-RED, Grafana, or InfluxDB later
If Solar Assistant is not an option, then my second choice is:
Inverter -> Modbus TCP/RS485 -> Home Assistant
The key principle is simple: local telemetry beats cloud telemetry. Every time.
What Hardware and Software You Need
Here is a practical starting stack.
Core pieces
- Home Assistant running on a mini PC, Home Assistant Green, NUC, VM, or Raspberry Pi
- Solar Assistant on a Raspberry Pi if your inverter supports it
- MQTT broker such as Mosquitto
- Reliable network connection, preferably Ethernet for anything stationary
- Your inverter communication cable: USB, RS232, RS485, or Ethernet depending on model
Optional but useful
- Smart plugs or relays for load control
- Shelly devices for contactors, water heaters, or resistive loads
- CT clamps / whole-home monitoring if your inverter data does not expose all flows cleanly
- InfluxDB/Grafana if you want long-term graph nerdery beyond Home Assistant’s default views
My bias on hardware
I would rather spend an extra $30 on better infrastructure than waste ten hours debugging packet loss, USB instability, or Wi-Fi dropout.
That means:
- use Ethernet where possible
- use quality USB serial adapters
- put Home Assistant on solid storage
- keep your MQTT broker local
Cheap hardware can make a good solar integration look flaky when the real problem is the bargain-bin adapter from the internet’s haunted garage sale.
Method 1: Solar Assistant + MQTT
This is the cleanest route for most people.
Step 1: Get Solar Assistant talking to the inverter
Before Home Assistant enters the picture, make sure Solar Assistant is already showing valid data for:
- PV power
- battery SOC
- battery voltage
- load power
- grid power or bypass state
- inverter mode/status
If Solar Assistant itself is not stable, stop there and fix that first. Do not stack Home Assistant on top of broken telemetry.
Step 2: Enable MQTT in Solar Assistant
In Solar Assistant, go to the MQTT settings page and enter:
- broker IP or hostname
- broker port, usually
1883 - username/password if configured
- topic prefix if you want something neat like
solarassistant/luxpower
Once enabled, Solar Assistant starts publishing sensor values that Home Assistant can discover automatically in many setups.
Step 3: Configure Mosquitto in Home Assistant
If you do not already have MQTT running:
- Install the Mosquitto broker add-on
- Create a dedicated user for MQTT access
- Start the broker
- Add the MQTT integration in Home Assistant
I strongly prefer dedicated credentials instead of reusing your admin account. Least privilege is still cool, even in a solar closet.
Step 4: Verify entities appear
After MQTT discovery kicks in, you should start seeing entities for things like:
- battery SOC
- inverter output power
- solar production
- AC charging state
- daily production totals
- grid import/export
Names vary depending on inverter support, but the core values should be there.
Step 5: Normalize entity names
This part is boring but worth it.
Rename ugly auto-discovered entities into something sane like:
sensor.solar_battery_socsensor.solar_pv_powersensor.solar_load_powersensor.solar_grid_powersensor.solar_daily_generationsensor.solar_inverter_mode
If you skip this, six months later you will be building automations around something like sensor.sa_8f3d_pwr_03 and cursing Past You.
Method 2: Direct Modbus Integration
If your inverter offers Modbus TCP or you have an RS485 bridge, Home Assistant can poll registers directly.
When direct Modbus makes sense
I like this route when:
- the inverter has a documented register map
- you want a minimal stack
- you are comfortable with YAML and register scaling
- you need values Solar Assistant does not expose the way you want
Example Modbus sensor structure
A typical Home Assistant modbus block looks something like this:
modbus:
- name: luxpower
type: tcp
host: 192.168.1.50
port: 502
sensors:
- name: Solar Battery SOC
unique_id: solar_battery_soc
slave: 1
address: 1060
input_type: holding
unit_of_measurement: "%"
data_type: uint16
- name: Solar PV Power
unique_id: solar_pv_power
slave: 1
address: 1071
input_type: holding
unit_of_measurement: W
data_type: uint16
That is only an example. The exact addresses depend on your inverter.
What usually goes wrong
Direct Modbus usually fails for one of these reasons:
- wrong slave ID
- wrong register type
- wrong byte order
- scaling factor not applied
- polling too aggressively
- RS485 adapter or wiring issues
If a value looks insane, like a 5,200-volt battery bank or negative sun, assume register interpretation is wrong before assuming physics broke.
Method 3: Vendor Cloud Integrations
Some inverters have Home Assistant integrations that pull from the manufacturer cloud.
This can be acceptable for lightweight monitoring, but there are drawbacks:
- updates may lag by 1 to 5 minutes
- some metrics are missing
- outages on the vendor side break your dashboard
- local automations become less trustworthy
I treat cloud integrations as a fallback, not the primary control plane.
If your only goal is a read-only wall tablet dashboard, fine. If you want automation decisions based on SOC, export power, or charging windows, local data is much better.
Setting Up the Home Assistant Energy Dashboard
Once your entities are stable, wire them into Home Assistant’s Energy dashboard.
At minimum, you want entities for:
- Solar production
- Home consumption
- Grid import
- Grid export
- Battery charge
- Battery discharge
- Battery SOC
A note on totals vs instantaneous power
This trips people up all the time.
The Energy dashboard usually wants cumulative energy sensors in kWh, not raw power sensors in watts.
That means:
sensor.solar_pv_powerin W is great for live dashboardssensor.solar_daily_generationor a utility meter-derived kWh sensor is what Energy wants
If your source only provides watts, use Home Assistant helpers such as:
- Integration helper to convert W into kWh over time
- Utility Meter helper for daily/monthly tracking
Example setup logic
If Solar Assistant gives you instantaneous PV power but not a cumulative total you like:
- Create an Integration sensor from PV watts
- Create Utility Meters for daily and monthly production
- Feed the resulting kWh sensor into the Energy dashboard
That gives you cleaner reporting and fewer weird graph gaps.
Building a Solar Dashboard That Tells the Truth
My preferred solar dashboard has two jobs:
- show live operating state
- show today’s outcome
My must-have live cards
- battery SOC
- PV power now
- load power now
- grid import/export now
- inverter mode
- battery charge/discharge power
- battery voltage and current
My must-have daily summary cards
- total solar generated today
- total imported from grid today
- total exported today
- minimum SOC overnight
- peak load today
- hours spent charging from solar vs grid
Why minimum overnight SOC matters
This is one of the most useful metrics in a hybrid or off-grid-adjacent system.
If your overnight minimum SOC keeps trending lower each week, you are not just “having a cloudy spell.” You probably have one of these problems:
- too much overnight base load
- battery not fully charging
- time-of-use schedule wrong
- solar production underperforming
- a new hidden load showed up
That kind of pattern is exactly what Home Assistant is good at exposing.
My Favorite Solar Automations
This is where the fun starts.
1. Excess solar load enabling
When PV production is high and battery SOC is healthy, turn on a discretionary load.
Good candidates:
- water heater
- dehumidifier
- pool pump
- EV charging at reduced current
- mini-split pre-cooling or pre-heating
Basic idea:
- if PV > 3000 W
- and battery SOC > 90%
- and grid import <= 100 W
- then enable the load
2. Low battery protection alerts
If SOC drops below a threshold overnight or earlier than expected, send a notification.
Example thresholds:
- warning at 30%
- urgent at 20%
- critical at 10%
3. Time-of-use charging control
If you are on utility rates with cheap overnight power, Home Assistant can coordinate charging windows intelligently.
For example:
- allow grid charging from 1 AM to 5 AM only if next-day forecast is poor
- skip overnight charging if tomorrow looks sunny and battery is already above 60%
That saves money and cycle wear.
4. Inverter fault or bypass detection
Alert if:
- inverter switches to bypass unexpectedly
- battery charging stops during a normal PV window
- solar production is zero despite clear daytime conditions
I like automations that tell me something is weird before I notice it from the couch.
Real Example: Battery-Aware Load Control
Here is a practical example.
Let’s say you want to run a water heater element only when the system has surplus solar.
Your conditions might be:
- battery SOC above 95%
- PV power above 2500 W
- house load below 1500 W
- no significant grid import
- time between 10:00 AM and 4:00 PM
If all of those are true for 5 minutes, turn on a smart relay.
If any of these happen, turn it back off:
- SOC drops below 90%
- PV falls under 1800 W
- grid import rises above 300 W
- it is after 4:00 PM
That sort of automation is where Home Assistant shines. You are no longer just watching energy. You are shaping load around production.
Common Problems and Fixes
Problem: Entities keep going unavailable
Usually caused by:
- bad Wi-Fi
- flaky USB serial adapter
- MQTT broker restart issues
- Solar Assistant or inverter comms instability
Fix the transport first. Unavailable entities make automations dumb.
Problem: Energy dashboard numbers do not match inverter app
This is common.
Possible causes:
- one source reports AC-side values, the other DC-side
- sensor resets at midnight unexpectedly
- units or scaling are wrong
- import/export direction is inverted
You need consistency more than perfection. Pick trusted sources and stick with them.
Problem: Automations chatter on and off
Use hysteresis and time conditions.
Bad automation:
- turn on above 2000 W
- turn off below 2000 W
Better automation:
- turn on above 2500 W for 5 minutes
- turn off below 1800 W for 5 minutes
That gap prevents rapid toggling when clouds start doing cloud nonsense.
Problem: Battery SOC is inaccurate
SOC can drift if:
- the inverter estimate is poor
- charge parameters are wrong
- BMS communication is limited
- the battery rarely reaches full calibration conditions
In that case, trust direct BMS data if you can get it. Good battery telemetry is worth its weight in aspirin.
Recommended Gear and Final Thoughts
If I were helping someone build a practical Home Assistant solar stack today, I would generally suggest:
- a reliable Home Assistant host on something sturdier than a random old SD card
- Solar Assistant if the inverter supports it
- Mosquitto MQTT for clean local data flow
- a few Shelly relays/plugs for smart load control
- good naming, helpers, and dashboards from day one
If you are trying to choose where to start, here is my blunt advice:
- get stable local data
- verify the values are believable
- set up the Energy dashboard
- add one or two genuinely useful automations
- ignore the temptation to build a dashboard that looks like a 747 cockpit before the basics work
The best solar automation setup is not the flashiest one. It is the one that helps you make better energy decisions without babysitting the system.
That is the whole point.
Author Bio
Bucky is a DIY solar enthusiast and network engineer who runs PanelsAndPackets.com to share real-world solar knowledge without the marketing fluff.