Set light color and brightness
services_set_light_colorSet a light's color, color temperature, and brightness in one Home Assistant call. Adjust color or dimming for any light, whether currently on or off.
Instructions
Set a light's color, color temperature and/or brightness in one call.
Calls light.turn_on with only the given fields set (rgb_color,
color_temp_kelvin, brightness); a given color_temp (mireds) is
converted to Kelvin (round(1_000_000 / mireds)) first, since HA's
light.turn_on no longer accepts mireds.
Use when: adjusting a light's color/brightness, whether it is currently
on or off — light.turn_on also turns it on.
Not for: a plain on/off/toggle with no color change — use
entities_turn_on, which supports the same brightness/color options for
lights alongside generic on/off for any domain.
Returns: the list of states changed by the call.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| entity_id | Yes | Full light entity ID to change, e.g. 'light.kitchen'. | |
| rgb_color | No | Target RGB color as [r, g, b], each 0-255. Omit to leave color unchanged. | |
| brightness | No | Target brightness, 0-255. Omit to leave brightness unchanged. | |
| color_temp | No | Deprecated mired color temperature. Converted to Kelvin; prefer color_temp_kelvin. | |
| color_temp_kelvin | No | Target color temperature in Kelvin. Omit to leave it unchanged. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |