Energy Dashboard: Realtime Energy Distribution

The energy distribution widget in the energy dashboard is awesome. However, it would be helpful if we could have a real-time view of this. Although the daily distribution is informative, knowing the current real-time distribution will help users make better informed decisions where they don’t already have automation to do the same (e.g., switch on or off a specific appliance to maximise self-consumption and self-sufficiency).

Are you asking to see an Instantaneous use Card that can be seen in the Energy Tab?
Something like this?
If so, that’s exactly what I am looking for.
I managed to set up my energy bridge to display energy usage in the Energy tab but have been unable to find a way to display the instantaneous usage. Instead I have it displayed on one of my other pages.

image

1 Like

There’s a Lovelace card for that in HACS: GitHub - gurbyz/power-wheel-card: An intuitive way to represent the power and energy that your home is consuming or producing. (A custom card for the Lovelace UI of Home Assistant.). Would be nice to have something like that integrated in the energy dashboard

1 Like
1 Like

This looks fantastic, I’ll be checking this out. The screenshot below shows my dashboard with real-time values and the home assistant energy card (which only updates every hour). Does your card support the non-fossil view as the default one does?

Hi @alexeiw123,

can you share the dashboard code here?

Thanks a lot

1 Like

Hey there’s a lot that goes in to building the entities for this dashboard. Since posting this I’ve changed it a fair bit - partly due to performance issues with my then setup (pi 3B+) and also to simplify the view a little. I’ve now changed to a HA yellow and I’ve been redo-ing this dashboard so I don’t really have working code for the full view to share right now until I fix it up how I like it. Is there a particular part you’re looking for?

The two main charts code is here:

    cards:
      - type: vertical-stack
        cards:
          - type: custom:apexcharts-card
            graph_span: 24h
            stacked: true
            update_interval: 30s
            all_series_config:
              stroke_width: 1
              unit: kW
              curve: smooth
              opacity: 1
              group_by:
                func: avg
                duration: 30s
                fill: zero
              type: area
              invert: true
              fill_raw: zero
              extend_to: now
              transform: return x / 1000;
              show:
                legend_value: false
            color_list:
              - '#7bc043'
              - '#0392cf'
              - '#1a936f'
              - '#c6dabf'
              - '#4071ed'
              - purple
              - orange
              - brown
              - pink
              - cyan
              - blue
              - '#6F4E37'
              - '#71797E'
            apex_config:
              chart:
                height: 175%
            span:
              start: day
            header:
              show: true
              title: Power Today
            series:
              - entity: sensor.solar_power_corrected_1m
                name: Generation
                type: line
                invert: false
                fill_raw: 'null'
                group_by:
                  func: raw
              - entity: sensor.grid_export_power_1m
                name: Export
                invert: false
                type: line
                fill_raw: 'null'
                group_by:
                  func: raw
              - entity: sensor.twc_charger_load_always_w
                name: EV Charger
              - entity: sensor.hot_water_system_supply_switch_0_power
                name: Hot Water
              - entity: sensor.fridge_current_consumption
                name: Fridge
              - entity: sensor.arlec_sw_washer_power
                name: Washer
              - entity: sensor.arlec_sw_dryer_power
                name: Dryer
              - entity: sensor.sw2_tvmedia_power
                name: Media
              - entity: sensor.eko_sw_dishwasher_power
                name: Dishwasher
              - entity: sensor.eko_sw_study_power
                name: Study
              - entity: sensor.ac_power_total_corrected
                name: Air Con
              - entity: sensor.arlec_sw_coffee_power
                name: Coffee Machine
              - entity: sensor.unmonitored_power
                name: Other
            yaxis:
              - id: first
                decimals: 0
                show: true
                apex_config:
                  forceNiceScale: true
                  title:
                    text: kW
          - type: custom:apexcharts-card
            apex_config:
              chart:
                height: 175%
            graph_span: 24h
            update_interval: 30s
            all_series_config:
              curve: smooth
            span:
              start: day
            header:
              show: true
              title: Cost Today
              show_states: false
              colorize_states: true
            yaxis:
              - id: first
                decimals: 0
                apex_config:
                  title:
                    text: $
                  forceNiceScale: true
            series:
              - entity: sensor.instant_cost_per_hour_1m
                name: Instant Cost Per Hour
                stroke_width: 1
                unit: $/h
                extend_to: now
                fill_raw: zero
                show:
                  legend_value: false
              - entity: sensor.today_energy_total_cost
                name: Daily Cost Accumulated
                type: area
                fill_raw: last
                show:
                  legend_value: false
                stroke_width: 1
                unit: $
                extend_to: now
                float_precision: 2

Take a look at this thread: Using Home Assistant to calculate my energy bill using data from my Solar Inverter
It goes in to the detail of how many of those entities are built. Obviously you’ll need to change a lot of this to suit your entities.

1 Like

Wanted to suggest the same! Accumulated energy distribution is nice, but of no needs. I would like to see what`s going on live.

I would like it too! My vote

Same, this has bugged me for years.

Put it under Settings > Dashboard > Energy.

Users can change their view to Real-Time, Day, or Week.

Having a config line that we can add under the Energy Distribution Card would be great too, so one could add both to a dashboard. No brainer

Voted

I am “sorry” to intervene in here, but I am still at a stage to understand if this graph in the Energy dashboard is real time or not ?
I think it is not, because it is representing ENERGY in kWh, and not using any power sensor that gives an instantaneous value in Watts …

Is this correct ?

I am looking for this graph, but showing real time data :

I see the dots moving on the lines letting us think it is LIVE … but I think it is not ?

Many Thanks !

1 Like

One year later I have the same question. Can anybody answer?

1 Like

I agree with cedricdelecole and aorb .
The energy distribution graph is (IMHO) perfect for realtime state and not for kWh, is there any way to use this graph with kW entities?

I totally agree. The energy graphic is misleading - it has “electrons” flowing, even though those don’t reflect the current status. Why show an animated electron if it’s a snapshot point in time?

The graphic really needs to show the current state of production / consumption. Even the total in kWh should be in realtime - you can create a use a Riemann sum to show this in realtime.

just to update this with some extra info:

are 2 alternatives and working nicely.

1 Like