Lovelace - hide/show views

Slowly getting more into the whole Lovelace thing - it’s great!

But it also poses a few new challenges for me on how to show things the way I want to see them, e.g.

Is there a way to show/hide whole views, i.e. make /lovelace/3 not show up in the tabs at the top?

Use case:
My alarm panel reports if it is ready to be armed, i.e. all doors and windows are closed/locked. If this is true, I show a closed lock on my main lovelace paned (/lovelace/0) panel and all is fine - I would then like to hide the picture elements view (/lovelace/3) that shows the floor plan with all the door and window sensors on it. Nothing to see there.

If it’s not the case, i.e. one or more windows/doors are open, the icon is an open lock and I would like the floor plan (/lovelace/3) to show up in the tabs so that I can check which door or window is not closed.

Is that possible?

Ideally, I would also like to be able to click directlyu on the open lock icon which takes me to the detailed view.
I assume I have to use a tap_action for that, but I cannot find out the syntax for it.

I don’t think it’s possible yet.

What you can do today is run a script upon tapping. The script can change group visibility on the same page.

Something like the following (I got this from a sample from someone else but I don’t remember where from. Didn’t use it yet).

alias: TV

  • data: {}
    service: switch.broadlink_send_packet_192_168_0_100
  • data:
    entity_id: group.tv_remote_cable
    visible: ‘true’
    service: group.set_visibility
  • data:
    entity_id: group.tv_remote_keypad
    visible: ‘false’
    service: group.set_visibility
  • data:
    entity_id: group.tv_remote_settings
    visible: ‘false’
    service: group.set_visibility
  • data:
    entity_id: group.tv_remote_source
    visible: ‘false’
    service: group.set_visibility
  • data:
    entity_id: group.tv_remote_list
    visible: ‘false’
    service: group.set_visibility
  • data:
    entity_id: group.tv_remote_guide
    visible: ‘false’
    service: group.set_visibility

Thanks @Joseph_Levy - this seems to be working for hiding and showing groups, but I have not managed to get it to work for a whole view yet.

Must have missed it in the documentation - or it wasn’t there yet when I looked :blush:

This is how to navigate from a status icon to another view:

# Ready To Arm Status
- type: state-icon
  entity: sensor.ready_to_arm
  tap_action: navigate
  navigation_path: '/lovelace/alarm_map'
    left: 60%
    top: 5% 

Thanks chairstacker
That looks very useful…cheers for posting!

Have found a workaround for hiding/showing views though? I have been searching all over but nothing useful yet?


Nope - haven’t found a way yet.
But I’m using conditional cards in the views, that reduces the clutter a bit.

My need is to reduce the number of views listed across the top and navigate from links within each view to ones needed for that view.

There must be a way I reckon. I will report back if I find anything that works.


So did you found anything? I would be thankfull for such an option too. Don’t show a button in the header, but navigate over adress or buttons (“hidden views”).

Sorry but I have not spent much time on figuring out a solution as I have had other HA issues to solve as well. I will revisit this problem soon (and post any updates) as it is an important one for me.

1 Like

Any progress?

No progress on this one sorry.
I have shifted my attention to running a two pronged solution.

I use lovelace for my more complicated processes (water treatment, power management, etc).

For my home automation I now use Node-RED.
I find it is very good for building interfaces for multiple platforms IE: Laptop, iPad and Android Phone.

I would also say that automations are more powerful yet relatively easy to construct.

Regards Steve Wells

yea, I use appdaemon for all of my automations. YAML is a pain and python is MUCH easier. Although the ability to hide views on only show the upstairs views or downstairs views would be nice.

I agree entirely…I have so many needs but only so much in the way of skills unfortunately.

I use a QNAP - Docker (Container Station) arrangement for my homeassistant
/mosquitto/Node-Red installations…appdaemon I would have liked as well BUT for whatever reason I cannot get that to work unfortunately.

If you want, I’m happy to help try getting appdaemon to work for you.