Files
homarr/apps/docs/docs/widgets/smart-home-entity-state/index.mdx
T
Thomas f18033ddaa fix: sync dev fixes into v2 and improve regression reports (#6821)
Co-authored-by: Homarr Update Contributors <210161987+homarr-update-contributors[bot]@users.noreply.github.com>
Co-authored-by: Crowdin Homarr <190541745+homarr-crowdin[bot]@users.noreply.github.com>
Co-authored-by: Releases Homarr <175486441+homarr-releases[bot]@users.noreply.github.com>
Co-authored-by: Thomas <thomas@ajnart.fr>
Co-authored-by: homarr-releases[bot] <175486441+homarr-releases[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: homarr-update-contributors[bot] <210161987+homarr-update-contributors[bot]@users.noreply.github.com>
Co-authored-by: homarr-crowdin[bot] <190541745+homarr-crowdin[bot]@users.noreply.github.com>
Co-authored-by: Afonso Jorge Ramos <afonsojorgeramos@gmail.com>
Co-authored-by: Danura30082 <danura30082+github@gmail.com>
Co-authored-by: Kushie <122986913+kushiemoon-dev@users.noreply.github.com>
Closes #6604
2026-09-12 15:31:04 +02:00

64 lines
2.2 KiB
Plaintext

---
title: "Entity State"
description: "Display the state of an entity and toggle it optionally"
hide_title: true
---
import { WidgetInteractionGuide } from "@site/src/components/widgets/interactions";
import { WidgetHeader } from "@site/src/components/widgets/header";
import { AddingWidget } from "@site/src/components/widgets/adding";
import { WidgetConfig } from "@site/src/components/widgets/configuration";
import { WidgetIntegrations } from "@site/src/components/widgets/integrations";
import { smartHomeEntityStateWidget } from ".";
import { homeAssistantIntegration } from "@site/docs/integrations/home-assistant";
<WidgetHeader widget={smartHomeEntityStateWidget} categories={["Smart home"]} />
The Entity State widget shows a Home Assistant entity's state and can optionally toggle it. Advanced view includes the
entity ID, unit, device class, icon, and update timestamps; arbitrary attributes are not exposed.
### Screenshots
import sun from "./img/sun.png";
import lightSwitch from "./img/light-switch.png";
import temperature from "./img/temperature.png";
<img src={sun} alt="smart-home-entity-state sun" width={128 * 1.5} height={128 * 1.5} />
<img src={lightSwitch} alt="smart-home-entity-state light-switch" width={128 * 1.5} height={128 * 1.5} />
<img src={temperature} alt="smart-home-entity-state temperature" width={128 * 1.5} height={128 * 1.5} />
### Supported Integrations
<WidgetIntegrations
items={[
{
integration: homeAssistantIntegration,
},
]}
/>
### Interactions
- Toggle entity state by clicking on the entity (only when clickable enabled).
- After a successful toggle, the displayed state refreshes immediately.
- If Homarr cannot refresh an entity, the last known state stays visible but toggling is disabled until the connection recovers.
<WidgetInteractionGuide />
### Adding the widget
<AddingWidget />
### Configuration
<WidgetConfig configuration={smartHomeEntityStateWidget.configuration} />
### Entity ID
Find the entity under **Home Assistant → Developer Tools → States** and copy its `domain.object_id` value.
import retrieveEntityId from "./img/retrieve-entity-id.png";
<img src={retrieveEntityId} alt="Home Assistant entity IDs under Developer Tools and States" width={256 * 2} />