Energy in Home Assistant: electricity, solar, battery and costs
Home Assistant can do more than display current electricity use.
With suitable data, it can combine grid import and export, solar production, home battery flows, costs and selected appliance consumption.
This provides a basis for both statistics and automations that run equipment under more favourable conditions.
Power and energy are not the same
Power, usually measured in watts or kilowatts, describes the current rate of consumption or production. Energy, commonly measured in kilowatt-hours, describes the amount transferred over time.
A device drawing 2000 W for one hour uses about 2 kWh. This distinction matters when selecting entities and configuring Energy statistics.
What can Home Assistant show?
Depending on the available sources, Home Assistant can display:
- energy imported from and exported to the grid;
- solar production;
- home battery flows;
- individual device consumption;
- energy costs;
- gas and water consumption.
Energy import and export
A home with solar has at least two important grid flows: import from the grid and export back to it.
Measuring both helps assess self-consumption and surplus. Data may come from a compatible meter, utility integration, inverter or additional monitoring device.
Solar production
Solar data may come from an inverter, energy meter or suitable integration.
Combining production with import and export reveals the energy flow more clearly than total production alone. It shows how much was used locally and when surplus occurred.
Home battery
If the system has a battery, Home Assistant can include energy charged into and discharged from it when suitable data is available.
The dashboard does not define the battery strategy. Control depends on the particular inverter, battery and integration.
Energy costs
The cost of 1 kWh may depend on the tariff, time, energy market, grid charges and billing rules. Pricing structures differ between countries and contracts.
Home Assistant can use cost data or price entities. Dynamic prices provide a basis for analysing when particular appliances are cheaper to run.
Individual device consumption
Compatible meters, smart plugs, monitoring modules and integrations can provide consumption data for individual devices.
This helps identify large loads and decide which ones may benefit from energy automation. Correct measurement hierarchies help prevent double counting.
Where can the data come from?
Sources include smart meters, meter ports, solar inverters, batteries, distribution-board meters, metering plugs and utility integrations.
Entities need the correct units and Home Assistant properties, including suitable device_class and state_class. No single product is right for every installation.
The Energy dashboard is only the beginning
Charts explain consumption, but greater value appears when automation uses the data.
Home Assistant can make decisions using energy prices, solar production, exported surplus, battery state, temperature, demand and time of day.
What can be automated?
Depending on the installation, energy data can control water heating, immersion heaters, EV charging, batteries, heating and other loads whose operating time can safely be shifted.
Not every load should follow price alone. Automation must also respect comfort, safety and equipment requirements.
Solar and surplus energy
When production exceeds consumption, surplus may be exported. In some systems, using part of it locally for water heating, battery charging or another flexible load can be preferable.
The result depends on import and export prices, efficiency and billing rules. The strategy must follow the data from the specific installation.
Electricity and heating
Energy prices and availability can contribute to heating control. Homes with several heat sources can compare the cost of producing the required heat.
Comparing 1 kWh of electricity with 1 kWh of fuel is not enough. Efficiency, heat-pump COP, charges, temperature and system constraints all matter.
Can Home Assistant reduce bills?
Home Assistant does not reduce consumption by itself. It can provide information and automation that uses energy when it is cheaper or available from your own production.
Actual savings depend on the installation, tariffs, controllable loads and household behaviour. No single percentage can be promised responsibly.
Where should you start?
First establish whether you have:
- meter import and export;
- solar production;
- battery charge and discharge;
- current energy prices;
- measurement of large loads;
- devices that can be controlled safely.
Only then is it worth designing the dashboard and automations.
Need help with energy in Home Assistant?
If you have solar, an energy meter, battery, dynamic prices or loads you want to align with cost and production, I can assess the installation and integration options.
I can also help prepare measurements, the Energy dashboard and automations using prices, solar production and actual consumption.
Contact me.The initial assessment of your request is free and without obligation. → click hereSources and currency
Checked on 13 August 2026 against current materials:
