Tap to show more-info of a different entity


I’m wondering if there is a way to change the tap behaviour in a lovelace entities card, such that when it is tapped, it shows the more-info pop-up of a different entity.

My use case is where I have an entities card with a whole bunch of switches / lights, I’d like the more-info pop-up to show the power consumption sensor for that switch / light.

For example, I’d like to be able to do something like this:

title: Downstairs
type: entities
  - entity: light.porch
    more-info: sensor.porch_power
  - entity: switch.ellies_light
    icon: 'mdi:lamp'
    more-info: sensor.ellies_light_power
  - entity: switch.bike_charger
    icon: 'mdi:bike'
    more-info: sensor.bike_charger_power



I tried this as well some months ago, i came back that this was only possible on the “glance” card. Don’t know if this is still the case. Been using the button card now, which can do the same. And way more :rofl:

My code back then was:

          - entity: light.yeelight_color1_34ce008b8e6e
            name: Licht TV Links
              action: toggle
          - entity: light.yeelight_color1_7811dcaa4d4e
            name: Licht TV Rechts
              action: toggle

You could thinker a bit with it to see if it works.

Did you figure out a solution for this? Looking for the exact same thing.

1 Like

I think this link has a answer:

The custom card multiple-entity-row allows you to pick any entity for the more-info pop-up.

I cannot cope with an apparently simple task. I have a temperature and thermostat position graph and I want the thermostat popup card to open when I click on the graph. Currently, after tapping the graph, the “more_info” service is called from the sensor entity. My configuration looks like that:

tap_action: call-service
service: browser_mod.more_info
  entity_id: climate.0x5c0272fffe7f71c4_climate
     - dashboard

Hi micque
It’s been a year since you posted, perhaps you can still help with this.
I tried tinkering with the multiple-entity-row card to get this to work but have not found the code to do that.

Sure, what exactly are you trying to do?

Hi wow you answered so quickly…
Im trying to set up a glance card that displays info from one entity but once clicked, a pop-up should show up with info from a different entity.
This is what I put in trying to use browser_mod with no luck so I’m trying the card you mentioned but don’t seem to be figuring out how to code it.

type: glance
  - entity: xyz
      action: call-service
      service: browser_mod.more_info
        entity_id: abc
          -  this
show_name: false
show_icon: false
state_color: false

Yeah what you have will simply run the service it won’t display it. You can only display more-info for an entity already existing in the system. For example

  - entity: alarm_control_panel.home
    type: custom:multiple-entity-row
    name: Alarm Panel
    icon: mdi:shield-home
      entity: alarm_control_panel.home
      name: false
    show_state: false
    state_color: true
      - entity: sensor.doors_open
        name: Doors
          entity: group.doors
          action: more-info
      - entity: sensor.lights_on
        name: Lights
          entity: group.lights
          action: more-info

Sensor.doors_open provides a nicely formatted text summary of the number of doors open and if you click on it, the more-info box displays the group.doors more-info which is a list of the doors and specifically which are open. Same with the lights, you get a list of lights and you can actually turn lights on or off from the dialog box which is nice.

So for your case, you would create a template sensor with the data in the state and attributes and then your UI would reference that template entity to display it’s more-info. Hope that helps.

Thank you for the reply.
I’m not sure I follow all of it though…
I already have the 2 entities in home assistant (they are both date related entities).
I’m not sure if I need to do more as you say “you would create a template sensor with the data in the state and attributes”

I wasn’t aware that you had other entities with the information. They may be fine for what you would like to display. I was just saying that multiple-entity-row utilizes existing entities for display. I have found that I’ve created a number of template entities whose only purpose is to collect or format information for multiple-entity-row to display in the UI.

Thank you - I will play with this a little

1 Like

Thank you - this does accomplish what I was trying to do! The only hookup is that I would like for the card to have the words centered and it is being pushed to the left side…

1 Like