[](https://github.com/hacs/integration) [](https://github.com/Gh61/lovelace-hue-like-light-card/actions/workflows/validation.yml) [](https://www.paypal.me/paygh61/)  # Hue-Like Light Card for Home Assistant This [dashboard](https://www.home-assistant.io/getting-started/concepts-terminology/#dashboards) card is providing light control. It is inspired by original Philips Hue app.
| Key | Type | Required | Since | Default | Description |
|---|---|---|---|---|---|
entity |
string | yes* | 1.0.0 | - | Light or switch (since 1.9.0) entity ID (eg. light.my_light) |
entities |
list of strings OR list of Entities | yes* | 1.0.0 | - | Multiple Light and/or switch (since 1.9.0) entity IDs |
floor |
string | yes* | 1.8.0 | - |
Name or ID of Floor with lights (eg. First floor or first_floor)
|
area |
string | yes* | 1.6.0 | - |
Name or ID of Area with lights (eg. Living room or living_room)
|
label |
string | yes* | 1.7.0 | - |
Name or ID of Label with lights (eg. Kitchen - desk or kitchen_desk)
|
groupEntity |
string | no | 1.6.0 | - | Light entity ID that represents the group of light entities (eg. light.my_light_group). Some platforms (like hue) will provide an entity representing the room, in addition to the individual light entities (might be disabled by default). This can be defined to toggle the lights all at once, rather than successively. |
title |
Text Template | no | 1.0.0 | Lights name | Card title |
description |
Text Template OR false |
no | 1.5.0 | automatic description | Description under the cards title. Placeholder %s can be used for showing number of lit lights. (eg. 'Is on: %s')If set to false, description will not show. |
icon |
string | no | 1.0.0 | automatic icon | Card icon |
iconSize |
Icon size | no | 1.4.2 | original |
Card icon size |
showSwitch |
boolean | no | 1.2.1 | true |
When set to false, toggle switch will not be visible on card. This will give more space for title.(You can then use offClickAction and onClickAction to turn the lights on/off.) |
switchOnScene |
string | no | 1.6.0 | - | Scene entity ID (eg. scene.office_bright).If set, this scene will be activated when switch changes from OFF to ON (instead of just runing all lights on). |
slider |
Slider type | no | 1.5.0 | default |
You can choose between diferent sliders or hide the slider. |
scenes |
list of Scenes OR empty list [] |
no | 1.1.0 | automatic detection | Scenes shown in Hue screen |
sceneOrder |
Scene Order | no | 1.5.0 | default |
Order of automatically detected scenes shown in Hue screen |
sceneProvider |
single OR list of Scene Providers | no | 1.11.0 | 'ha-scenes' |
The provider(s) of scenes to be displayed |
allowZero |
boolean | no | 1.0.0 | false |
If turned on, the slider can be moved to and from value 0. (turning off/on the the lights) |
liveUpdate |
boolean | no | 1.12.0 | true |
If turned on, the lights are updated continuously while dragging the slider, color picker marker or brightness bar. If turned off, the lights are updated only when dragging ends. See Live updates. |
defaultColor |
Color | no | 1.0.0 | 'warm' |
If selected light (or lights) doesn't have RGB mode, this value is used as color when the light is on. |
offColor |
ColorExtended | no | 1.0.0 | '#666'( '#363636' for Hue Screen) |
The color of the pane, when all lights are off.
When set, also used in Hue Screen header (recommended setting also hueScreenBgColor accordingly).
|
hueScreenBgColor |
ColorExtended | no | 1.1.0 | '#171717' |
Background color of Hue Screen |
theme |
Installed theme name | no | 1.2.1 | Global HA theme | Will use specific theme for this single card. Other than the current selected globally in Home Assistant. |
disableOffShadow |
boolean | no | removed in 1.6.0 | false |
|
offShadow |
boolean | no | 1.3.0 | true |
If turned off, the card will not have inner shadow, when all lights are off. |
hueBorders |
boolean | no | 1.0.0 | true |
If turned off, the card will take border settings from current Home Assistant theme. |
apiId |
string | no | 1.7.0 | - | Identifier of the card for the API interface. |
isVisible |
boolean | no | 1.7.0 | true |
If turned off, the card will be hidden. (Use this if you only want the API functions.) |
resources |
Resources object | no | removed in 1.5.0 | - | Replaced with integrated localization. |
style |
no | 1.4.0 | - | Support for the card-mod. | |
card_mod |
no | 1.4.0 | - | Support for the card-mod. | |
* At least one of these options must be filled in. Only entities of light domain and/or floors, areas and labels with light domain entities are supported.
|
|||||
| Key | Type | Required | Since | Description |
|---|---|---|---|---|
entity |
string | yes | 1.4.1 | Light or switch (since 1.9.0) entity ID (eg. light.my_light) |
title |
string | no | 1.8.0 | Light title shown on Hue Screen |
icon |
string | no | 1.8.0 | Light icon shown on Hue Screen |
| Key | Type | Required | Since | Default | Description |
|---|---|---|---|---|---|
offClickAction |
Action | no | 1.1.0 | hue-screen |
Action when tile is clicked and all lights are off |
offClickData |
Action Data | no | 1.1.0 | - | Data for offClickAction |
onClickAction |
Action | no | 1.1.0 | hue-screen |
Action when tile is clicked and any of lights is on |
onClickData |
Action Data | no | 1.1.0 | - | Data for onClickAction |
offHoldAction |
Action | no | 1.6.0 | more-info |
Action when tile is pressed and all lights are off |
offHoldData |
Action Data | no | 1.6.0 | - | Data for offHoldAction |
onHoldAction |
Action | no | 1.6.0 | more-info |
Action when tile is pressed and any of lights is on |
onHoldData |
Action Data | no | 1.6.0 | - | Data for onHoldAction |
'#fff', '#ffffff''#fffa', '#ffffffaa' (since version 1.4.0)'rgb(255,255,255)''rgba(255,255,255,0.9)' (since version 1.4.0)'red','salmon','DarkSeaGreen', etc.'warm' or 'cold' (in places where it does make sense)theme-color| Key | Possible data* | Data required | Since | What is happening |
|---|---|---|---|---|
default |
yes | no | 1.1.0 |
Click: hue-screenHold: more-info
|
none |
no | no | 1.1.0 | nothing |
turn-on |
no | no | 1.1.0 | turn on all lights |
turn-off |
no | no | 1.1.0 | turn off all lights |
more-info |
yes (entity) |
no | 1.1.0 (group entity 1.8.0) |
Shows system more-info dialog of one light. Uses group entity, if set. Uses first lit light if any. Uses first light as backup. When action data are used, any entity can be used. |
scene |
yes (scene) |
yes | 1.1.0 | activate selected scene |
hue-screen |
no (is using general scenes config) |
no | 1.1.0 | show Hue Screen |
| Name | Since | Description |
|---|---|---|
{apiId}_openHueScreen |
1.7.0 | Will open Hue Screen of the identified card |
scenes: []
### Scene parameters
| Key | Type | Required | Since | Default | Description |
|---|---|---|---|---|---|
entity |
string | yes | 1.1.0 | - | Scene entity ID (eg. scene.tv_orange) |
title |
string | no | 1.1.0 | Scene name* | Text on scene-button |
icon |
string | no | 1.1.0 | Icon of scene or 'mdi:palette' |
Icon on scene-button |
color |
Color | no | 1.1.0 | 'darkgoldenrod' |
Accent color current scene (shown on scene-button) |
activation |
Service name | no | 1.2.0 | 'scene.turn_on' |
Service called when scene is activated |
activationData |
object | no | 1.2.0 | - | Data for activation service.** |
| * If the scene name begins with the same text as the card title is, this text is removed. | |||||
** Data always have entity_id parameter filled with entity name. You can change this value, when another value is supplied with this name.
|
|||||

## Examples of configuration
#### Area

```yaml
type: custom:hue-like-light-card
area: Living room
icon: mdi:sofa
offColor: '#363636'
```
#### Multiple lights

```yaml
type: custom:hue-like-light-card
title: TV colors
entities:
- light.tvlight_color1
- light.tvlight_color2
- light.tvlight_color3
- light.tvlight_color4
```
#### Custom title and icon

```yaml
type: custom:hue-like-light-card
entity: light.livingroom_lamp
title: Reading light
icon: mdi:floor-lamp
```
#### No toggle switch

```yaml
type: custom:hue-like-light-card
title: '[ TV - {{ light.tv_backlight }} ] No switch = more space for title'
entity: light.tv_backlight
icon: mdi:television
showSwitch: false
offClickAction: turn-on
onClickAction: turn-off
offColor: rgb(28,28,28)
```
#### Home Assistant-like

```yaml
type: custom:hue-like-light-card
title: TV colors
entities:
- light.tvlight_color1
- light.tvlight_color2
- light.tvlight_color3
- light.tvlight_color4
offColor: theme-color
hueScreenBgColor: theme-color
offShadow: false
hueBorders: false
```
#### Turnable with slider

```yaml
type: custom:hue-like-light-card
title: Living room
entity: light.livingroom_light
allowZero: true
```
#### Custom theme

```yaml
type: custom:hue-like-light-card
title: Living room
icon: mdi:sofa
offColor: theme-color
hueScreenBgColor: theme-color
offShadow: false
hueBorders: false
allowZero: true
entities:
- light.livingroom_light
- light.livingroom_color
theme: synthwave
```
#### Non-RGB Light

```yaml
type: custom:hue-like-light-card
title: Bathroom
iconSize: big
entity: light.bathroom
defaultColor: 'rgb(230,230,255)'
```
#### No description

```yaml
type: custom:hue-like-light-card
entity: light.office
description: false
```
## Coming soon features
- ui editor?