/web/COM0 Afri Blanck, Engineer
Blog / 2026-11-05

Home Assistant: naming untracked consumption per upstream device

#home-assistant #energy

This article describes how the untracked consumption of an upstream device receives its own name in the Home Assistant energy dashboard. Home Assistant provides no per-device name for this remainder. Therefore, the remainder is computed by a separate sensor and added as a device under the parent.

Problem

Finding

Procedure

The example uses a metered plug (Network Hub) that feeds a miner (NerdQAxe), which reports its own power.

  1. Add a template sensor that subtracts the child power from the parent power, floored at zero (Listing 1).
  2. Add an integral sensor that converts W to kWh with a left Riemann sum (Listing 1).
  3. Restart Home Assistant.
  4. Open Settings → Dashboards → Energy → Individual devices → Add device and enter the values of Table 1.
Listing 1: The template sensor computes the remainder in W. The integral sensor converts it to kWh.
template:
  - sensor:
      - name: network_hub_rest_power
        unique_id: network_hub_rest_power
        unit_of_measurement: W
        device_class: power
        state_class: measurement
        availability: "{{ has_value('sensor.plug_m3_network_hub_network_hub_power') }}"
        state: >
          {{ [states('sensor.plug_m3_network_hub_network_hub_power') | float(0)
              - states('sensor.nerdqaxe_power') | float(0), 0] | max | round(1) }}

sensor:
  - platform: integration
    name: network_hub_rest_energy
    unique_id: network_hub_rest_energy
    source: sensor.network_hub_rest_power
    unit_prefix: k
    unit_time: h
    method: left
    round: 3
    max_sub_interval:
      minutes: 5
Table 1: The remainder is added as an individual device with the following values.
FieldValue
Energy sensorsensor.network_hub_rest_energy
Power sensorsensor.network_hub_rest_power
Display nameNetwork Hub Rest
Upstream deviceNetwork Hub

The miner keeps Network Hub as its upstream device.

Verification

Limitations

Alternative

The Sankey Chart card from the Home Assistant Community Store (HACS) can be used on a custom dashboard. Its node type remaining_parent_state takes a free name per parent. However, the chart configuration must be maintained by hand.