Flame effect
Use this action to start the firmware-based Flame effect on a matrix LIFX light, such as the LIFX Tile or Candle. The effect animates a warm, flickering flame across the light, which makes it a nice fit for a mantelpiece, a dinner table, or a cozy corner of a room.
The Flame effect runs on the light itself, so it keeps going even if Home Assistant restarts. To stop it, use Stop effect.
Using this action from the user interface
If you prefer building automations and scripts visually, Home Assistant walks you through this action step by step. You pick what to target, tweak a few options, and save. No YAML knowledge required.
To start the Flame effect from an automation or a script:
- Go to Settings > Automations & scenes.
- Open an existing automation or script, or select Create automation > Create new automation.
- If you’re setting up a new automation, add a trigger in the When section. Scripts don’t need a trigger. They run when something else calls them.
- In the Then do section, select Add action.
- From the search box, search for and select Flame effect.
- Select what you want to control. Under By target (see Targets), pick the area your LIFX lights are in (like your living room or bedroom). You can also select a floor, a device, a specific entity, or a label.
- Set Speed to control how quickly the flames move. Lower values make a livelier flame, higher values a slower one.
- Select Save.
Options in the UI
How long, in seconds, one complete animation cycle takes. Choose a whole number between 1 and 25. Defaults to 3 seconds.
Using this action in YAML
If you work directly in YAML, or you want to know exactly what Home Assistant does under the hood, this section has the technical reference. It lists the field names you use in YAML, their types, and which ones are required.
In YAML, refer to this action as lifx.effect_flame. A basic example looks like this:
action: lifx.effect_flame
target:
entity_id: light.mantel_candle
data:
speed: 5
This starts a slow, gentle flame on the mantel candle, taking five seconds for one complete cycle.
Options in YAML
Targets of the action
This action requires a target. The target is the object of the action. You can point the action at a single entityAn entity represents a sensor, actor, or function in Home Assistant. Entities are used to monitor physical properties or to control other entities. An entity is usually part of a device or a service. [Learn more], a device, an area, a floor, or a label, and Home Assistant will run the action on every matching light entity behind that target.
-
Entity: one specific light entity, such as
light.living_room. - Device: every light entity that belongs to a device.
- Area: every light entity in a room or area.
- Floor: every light entity on a floor.
- Label: every light entity that shares a label.
You can also select different target types in one action. For example, you can add a specific entity and an area as targets in the same action to run the action on both of them at once.
Good to know
- Only matrix lights run the Flame effect. That means the LIFX Tile, Candle, Path, Spot, Tube, Luna, Mirror, and Ceiling. If your target also covers other LIFX lights, those lights are skipped and the rest of the action still runs.
- When you target lights by entity and none of them is a LIFX light, the action fails with the message “The targets of action lifx.effect_flame include no LIFX light”. If they include LIFX lights but no matrix light, it fails with “The targets of action lifx.effect_flame include no LIFX matrix light”. When you target an area, floor, device, or label instead, lights the effect cannot run on are left alone and no error is returned.
- The Flame effect uses its own built-in colors, so it has no theme or palette option. If you want to choose the colors yourself, use Morph effect instead.
- Power on is on by default, so a light that is off is turned on before the effect starts.
- To stop the animation, use Stop effect.
- You can also start this effect with default options by calling Turn on a light with the effect set to
effect_flame.
Try it yourself
Ready to test this? Open Settings > Tools > Actions, search for this action, fill in the fields, and select Perform action. You see what happens on your actual entitiesAn entity represents a sensor, actor, or function in Home Assistant. Entities are used to monitor physical properties or to control other entities. An entity is usually part of a device or a service. [Learn more] without writing a line of YAML.
More examples
Real scenarios where this action shows up in automations and scripts. Copy any example and adapt it to your setup. In the visual editor, select the UI options listed in the example or paste the YAML code.
You don’t need to edit YAML to use these examples. Copy a YAML snippet from this page, open the visual automation editor in Home Assistant, and press Ctrl+V (or Cmd+V on Mac). Home Assistant automatically converts the pasted YAML into the visual editor format, whether it’s a full automation, a single trigger, a condition, or an action.
Automation: light a virtual candle at sunset
Start a gentle flame on the mantel candle every evening as the sun goes down.
- Trigger: Sunset
-
Action: Flame effect
-
Target: Mantel candle (
light.mantel_candle)
-
Target: Mantel candle (
alias: "Light the mantel candle at sunset"
triggers:
- trigger: sun
event: sunset
actions:
- action: lifx.effect_flame
target:
entity_id: light.mantel_candle
data:
speed: 6
Automation: greet visitors after dark
When the front door opens after sunset, run a lively flame on the entryway tiles for one minute, then stop it.
- Trigger: Front door opens
- Condition: The sun is below the horizon
-
Action: Flame effect
-
Target: Entryway tiles (
light.entryway_tiles)
-
Target: Entryway tiles (
-
Action: Stop effect
-
Target: Entryway tiles (
light.entryway_tiles)
-
Target: Entryway tiles (
alias: "Flame welcome at the front door"
triggers:
- trigger: state
entity_id: binary_sensor.front_door
to: "on"
conditions:
- condition: sun
after: sunset
actions:
- action: lifx.effect_flame
target:
entity_id: light.entryway_tiles
data:
speed: 1
- delay:
minutes: 1
- action: lifx.effect_stop
target:
entity_id: light.entryway_tiles
Still stuck?
The Home Assistant community is quick to help: join Discord for real-time chat, post on the community forum with the action you’re calling and what you expected to happen, or share on our subreddit /r/homeassistant.
AI assistants like ChatGPT or Claude can also explain actions or suggest the right one when you describe what you want in plain language.
Related actions
Explore related actions:
-
Morph effect: Start the firmware-based Morph effect on a matrix LIFX light, such as the LIFX Tile or Candle.
-
Sky effect: Start a firmware-based effect that animates a sky scene across a LIFX Ceiling, Luna, Mirror, E26 Candle, or E26 Tube.
-
Paint theme: Paints either a provided theme or custom palette across one or more LIFX lights.
-
Stop effect: Stop a running effect on LIFX lights.