Skip to main content

Track Status Light

Turn any RGB light into a live F1 race status indicator. The light color changes automatically to reflect the current track condition — green for clear racing, yellow for caution, red for a red flag, and distinct colors for Safety Car and Virtual Safety Car.

The blueprint is built around the Track Status and Session Status sensors from F1 Sensor, and includes optional gates for presence, media player state, and a do-not-disturb time window.

Sync with your TV

For the light to change at the same time as you see the flag on screen, configure the Live Delay to match your broadcast offset.


Import the Blueprint

Open your Home Assistant instance and show the blueprint import dialog with a specific blueprint pre-filled.

Or go to Settings > Automations & Scenes > Blueprints and import manually using the URL:

https://raw.githubusercontent.com/Nicxe/f1_sensor/main/blueprints/f1_session_track_status.yaml

Requirements

  • F1 Sensor integration installed with live data enabled
  • An RGB-capable light entity in Home Assistant

Step-by-step Setup

Step 1 — Create an automation from the blueprint

  1. Go to Settings > Automations & Scenes > Blueprints
  2. Find F1 Sensor - Track Status Light (Modern)
  3. Click Create Automation

Step 2 — Data Sources

Link the blueprint to the correct F1 Sensor entities.

SettingDescription
Session Status SensorSelect the *_session_status sensor. This determines when the automation is active
Track Status SensorSelect the *_track_status sensor. This drives the light color
Active Session PhasesThe light only updates when the session is in one of these phases. Defaults to live and suspended
Session phases

The session goes through a sequence of phases during an event. During pre, break, finished, finalised, and ended the light will not update unless you include those phases in the active list. See Session Status values for the full list.


Step 3 — Session Scope (Optional)

Limit the automation to specific session types, for example only during Race and Qualifying, while ignoring Practice sessions.

SettingDescription
Enable Current Session FilterWhen enabled, the light only updates during the selected session types. Disabled by default
Current Session SensorSelect the *_current_session sensor. Required when the filter is enabled
Allowed Current SessionsWhich session types should activate the light. Defaults to all sessions
info

When this filter is enabled, the automation checks the Current Session sensor to decide whether to run. If the session type is not in the allowed list, light updates are suppressed entirely for that session.


Step 4 — Light Behavior

SettingDescription
Light EntitySelect the RGB light that should follow track status
BrightnessBrightness percentage when the light turns on. Defaults to 100%
Transition TimeHow long color changes take in seconds. Defaults to 1s
Snapshot Light At Session StartSaves the current light state when the session enters active phases. Used to restore the light to its pre-race state when the session ends. Defaults to on
Snapshot Before AlertsSaves the light state before a YELLOW, RED, SC, or VSC update. Used to restore the light after an alert clears. Defaults to on
About snapshots

Snapshots are temporary scenes stored in Home Assistant for the duration of the session. They allow the blueprint to restore your light to exactly how it looked before an incident — for example, going back to your normal living room scene once a yellow flag clears. They are automatically deleted when the session ends, unless you disable Delete Runtime Scenes On Session End in the session end settings.


Step 5 — Flag Colors

Set the RGB color for each track status. These settings are collapsed by default and come with sensible defaults.

Track StatusDefault ColorWhen it appears
CLEARGreen [0, 255, 0]Normal racing conditions
YELLOWYellow [255, 255, 0]Caution, hazard on track
REDRed [255, 0, 0]Session stopped
VSCYellow [255, 255, 0]Virtual Safety Car deployed
SCRed [255, 0, 0]Safety Car deployed

Step 6 — Alert Behavior

Configure how the light behaves during flag alerts. YELLOW and RED share one set of options, while SC and VSC share another. All settings in this section are collapsed by default.

Flash Interval controls the time between on and off pulses for any flashing mode.

YELLOW and RED

SettingDescription
YELLOW/RED ModeHow the light behaves when YELLOW or RED is active
YELLOW/RED Flash DurationHow long the light flashes before switching to the after-flash behavior. Used only in timed mode. Defaults to 10s
YELLOW/RED After Timed FlashWhat the light does after timed flashing ends

SC and VSC

SettingDescription
SC/VSC ModeHow the light behaves when SC or VSC is active
SC/VSC Flash DurationHow long the light flashes before switching to the after-flash behavior. Used only in timed mode. Defaults to 10s
SC/VSC After Timed FlashWhat the light does after timed flashing ends

Available modes:

ModeBehavior
Steady color onlyLight switches to the flag color without flashing
Flash for a duration then continueLight flashes for the configured duration, then switches to the after-flash setting
Flash continuously until status changesLight keeps flashing until the track status changes away

After timed flash options:

OptionBehavior
Keep steady colorLight stays on the flag color
Restore pre-alert sceneLight restores to the state it was in before the alert began (requires Snapshot Before Alerts to be enabled)

Step 7 — CLEAR Behavior

Configure what the light does when the track status returns to CLEAR. This section is collapsed by default.

SettingDescription
CLEAR ModeHow the light responds when CLEAR is received
CLEAR Restore DelayHow long the light shows the CLEAR color before restoring. Used only in delayed restore mode. Defaults to 5s

Available modes:

ModeBehavior
Keep CLEAR colorLight switches to the CLEAR color and stays there
Restore pre-alert scene immediatelyLight restores to the state it was in before the alert, skipping the CLEAR color entirely
CLEAR color then restore after delayLight shows the CLEAR color briefly, then restores to the pre-alert state after the configured delay
info

The restore options require Snapshot Before Alerts to be enabled in the Light Behavior section.


Step 8 — Activation Conditions (Optional)

These optional gates must all pass before the light updates. All are disabled by default.

SettingDescription
Presence DevicesSelect one or more device trackers. At least one must be home for the light to update
Media Player GateSelect a media player. The light only updates when the player is on, idle, or playing
Enable Do Not Disturb WindowBlock light updates during a specific time window
DND Start TimeWhen the DND window begins. Defaults to 23:00
DND End TimeWhen the DND window ends. Defaults to 07:00. Overnight windows (e.g. 23:00–07:00) are supported

Step 9 — Session End Behavior (Optional)

Configure what happens to the light after the session leaves the active phases. This section is collapsed by default.

SettingDescription
End DelayWait this many minutes after the session ends before applying the end action. Defaults to 0
End ActionWhat to do after the delay
Neutral ColorColor used when End Action is set to Set neutral color. Defaults to white
Delete Runtime Scenes On Session EndRemoves the temporary pre-race and pre-alert scenes from Home Assistant after the end action runs. Defaults to on

End action options:

OptionBehavior
Keep current light stateThe light stays exactly as it was when the session ended
Turn off lightThe light turns off
Set neutral colorThe light switches to a neutral color of your choice
Restore pre-race sceneThe light restores to the state it was in when the session started (requires Snapshot Light At Session Start to be enabled)

Step 10 — Notifications (Optional)

The blueprint can also send notifications on track status changes and session end. This section is collapsed and disabled by default.

SettingDescription
Enable NotificationsMaster switch for all notification actions
Notify on Track Status UpdatesSend a notification each time the track status changes
Notify on Session EndSend a notification when the session leaves the active phases
Notification ActionsAdd one or more Home Assistant actions for delivery

Available template variables in notification actions:

VariableDescription
{{ notification_title }}Pre-built title (F1 Track Status or F1 Session Ended)
{{ notification_message }}Pre-built message describing the change
{{ notification_track_state }}Current track status in uppercase
{{ notification_session_phase }}Current session phase in lowercase

Testing

You can simulate track and session changes without waiting for a live session.

  1. Go to Developer Tools > States
  2. Find your *_track_status or *_session_status entity
  3. Set the state manually to any valid value (e.g. SC, RED, live)

The automation will react immediately as if the sensor had changed naturally.

info

Valid track status values: CLEAR, YELLOW, VSC, SC, RED

Valid session phase values: pre, live, suspended, break, finished, finalised, ended


How it works

The automation has two triggers: one for track status changes and one for session status changes. When a track update arrives and all conditions pass (active session phase, presence, media player, DND window), the light switches to the matching color.

When a session enters active phases, an optional snapshot of the light state is saved. Before each YELLOW, RED, SC, or VSC update, another optional snapshot is taken. These snapshots allow the automation to restore the light to its previous state — either after an alert clears, or when the session ends.

YELLOW, RED, SC, and VSC each support three modes: a steady color, timed flashing (flash for a set duration, then continue with either steady or a restore), or continuous flashing until the status changes away.

When the CLEAR status arrives, the light can show the clear color, restore immediately to the pre-alert state, or show the clear color briefly before restoring.

When the session leaves active phases, the configured end action runs after an optional delay. Temporary scenes created during the session are cleaned up automatically when the session ends.