Fire manual event

Use this action to fire an event. Other automations can react to it with a Manual event received trigger. This lets one automation or script tell another that something happened, and pass data along.

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 fill in a few options and save. No YAML knowledge required.

To fire an event from an automation or a script:

  1. Go to Settings > Automations & scenes and select an automation. To edit a script, go to the Scripts tab and select the script.
  2. In the Then do section of an automation, or the Sequence section of a script, select Add action.
  3. Search for and select Fire manual event.
  4. In Event type, enter the name of the event, for example, event_light_state_changed.
  5. Optional: In Event data, enter the data to send with the event, in YAML.
  6. Select Save.

Options in the UI

Event type (Required)

The name of the event to fire.

Event data (Optional)

The data to send with the event, as keys and values in YAML. The values can be templates.

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, use event with the event type, and optionally event_data:

ActionAn action makes Home Assistant do something, for example, turn on a light, send a notification, or activate a scene. Automations and scripts run a list of actions. [Learn more]
event: MY_EVENT
event_data:
  room: kitchen

The values in event_data can be templates.

Options in YAML

event string Required

The name of the event to fire.

event_data map (Optional)

The data to send with the event. The values can be templates.

Good to know

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.

Tip

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: Fire a custom event when a switch turns on

When the kitchen switch turns on, this automation fires the custom event event_light_state_changed, with the new state as event data. The actions could also be part of a script.

YAML example
AutomationAutomations in Home Assistant allow you to automatically respond to things that happen in and around your home. [Learn more]
alias: "Fire event"
triggers:
  - trigger: state
    entity_id: switch.kitchen
    to: "on"
actions:
  - event: event_light_state_changed
    event_data:
      state: "on"

Automation: React to the custom event

This automation reacts to event_light_state_changed with a Manual event received trigger, and uses the state from the event data in a notification. For the data you can use, refer to available trigger data.

YAML example
AutomationAutomations in Home Assistant allow you to automatically respond to things that happen in and around your home. [Learn more]
alias: "Capture event"
triggers:
  - trigger: event
    event_type: event_light_state_changed
actions:
  - action: notify.notify
    data:
      message: "The kitchen light is turned {{ trigger.event.data.state }}."

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.

Tip

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: