How to show an attribute on a glance card?

Is the only way to show an attribute in a glance to extract it using a template sensor?

I have 2 climate entities that are part of a single z wave thermostat. I want to show on my mobile phone the min/max target set temp as well as the actual temperature.

1 Like

In a Glance card?

Yes.

There’s a custom Lovelace attributes card but it shows them as a list.

Yea i have seen that one but not a fan of the table as it looks like an eye sore. Yea i thought that was the only way. OK i will go about it that way and make an template sensor for the attribute.

Instead of using type ‘- entity: …’ use ‘- type: attribute: …’.
Example:

  - type: attribute
    icon: mdi:radiator
    name: Heater Mode
    entity: climate.lyric
    attribute: hvac_action

Result:
image

The only limitation is that it cannot be used with visual editor.

2 Likes

That was not available three years ago.

And it is still not valid now. Glance cards do not support attributes. What you are showing is the state.

1 Like

I know this post is old, but I came here from a google and it gave me insight into how to achieve it with what I had available which was the stack-in-card (GitHub - custom-cards/stack-in-card: 🛠 group multiple cards into one card without the borders) HACS addon,

With this I was able to use:

type: custom:stack-in-card
title: Electric Prices
mode: horizontal
cards:
  - type: horizontal-stack
    cards:
      - type: entity
        entity: sensor.octopus_agile_prices
        attribute: import
        name: Price Now
        unit: p
        icon: mdi:currency-gbp
      - type: entity
        entity: sensor.octopus_agile_prices
        attribute: import_next
        name: Price Next
        unit: p
        icon: mdi:currency-gbp

To achieve what I wanted, Now and Next electric unit prices next to each other from attributes of a sensor.
image