Skip to content

Home Assistant integration for @foxglove

Notifications You must be signed in to change notification settings

jtbandes/hass-foxglove-bridge

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Home Assistant Foxglove Bridge

This integration enables Home Assistant data to be visualized with Foxglove. You can view a live dashboard, or record to a MCAP file.

Setup

  1. Ensure you have installed the Home Assistant Community Store integration (HACS).

  2. Add this repository to HACS:

    Open your Home Assistant instance and open a repository inside the Home Assistant Community Store.

  3. Set up the "Foxglove Bridge" integration:

    Open your Home Assistant instance and add a Foxglove Bridge integration.

  4. Follow the steps to add the integration. Leave the host and port settings at their default values unless you have a reason to use different settings.

    Foxglove Bridge integration settings dialog

Usage

Live visualization

  1. Once the integration is configured, open Foxglove in Chrome, click "Open connection" and enter your Home Assistant URL followed by the port number configured when setting up the integration, usually 8765. (See Foxglove docs)

    For example, if your Home Assistant URL is homeassistant.local, you can visit: https://app.foxglove.dev/~/view?ds=foxglove-websocket&ds.url=ws://homeassistant.local:8765

    Open Connection dialog in Foxglove
  2. If you receive a security error, click the shield icon in the address bar and select "Load Unsafe Scripts". This error appears because the browser by default doesn't allow an https page to connect to servers that aren't using SSL.

  3. Browse the list of available entities in the Topics sidebar on the left. You can view an entity's state by using a panel (analogous to a Home Assistant Card). Click the Add Panel button in the top bar, and try adding a Raw Messages panel to view states and attributes for a single entity.

    Adding a Raw Message panel Visualizing entity states in the Raw Message panel
  4. For numeric or discrete data, try using the Plot or State Transitions panels for visualization:

    Viewing data in Plot and State Transitions panels

Services

When using a live connection, you can use Foxglove's Service Call panel to invoke Home Assistant Actions (a.k.a. Services).

In the panel settings, select from the available services. Enter your request parameters as JSON in the "Request" box and click the button to call the service.

Call a service using the Service Call panel

MCAP recording

  1. Visit the integration's service settings page and toggle the "MCAP Recording" switch on. This will start logging state changes to an MCAP file.

    MCAP recording
  2. Turn the switch off again to stop recording.

  3. The MCAP file will be saved to your media directory, for example /media/foxglove_bridge/home_assistant_1743012122854908268.mcap.

  4. Once you have an MCAP file, you can inspect it using the MCAP CLI, APIs, or by viewing it in Foxglove.

Sponsor this project

  •  

Languages