Crashes, No Sound, or Screen Glitches?
Random freezes, missing sound and display glitches usually trace back to one bad driver. Find and replace yours safely.Free scan · under a minutePC Slower Than It Used to Be?
A free scan shows the junk files, broken settings and background clutter dragging Windows down - then fixes them in one click.Free scan · Windows 10 & 11iTechGuides is reader-supported. When you buy through links on our site, we may earn an affiliate commission. As an Amazon Associate I earn from qualifying purchases. Learn more
In Home Assistant, unknown means no state value is known for the entity. unavailable means the entity cannot provide its state right now. The distinction is useful for troubleshooting, but neither label is a complete diagnosis. An unavailable entity might be powered off, unreachable over the network, connected to a service that is down, or waiting for its integration to finish setting up. An unknown result can also be caused by a misspelled or nonexistent entity ID.
Check the entity’s raw state in Settings > Tools > States, then use the matching diagnostic path. In templates and automations, test whether an entity has a usable value before performing calculations or making decisions.
The two states at a glance
Every Home Assistant entity has one current state value. Typical values include on, off, a temperature such as 21.5, or a person state such as home. Attributes, such as a battery percentage or friendly name, are additional data and are separate from the main state.
| State or case | What it means | First check |
|---|---|---|
unknown |
Home Assistant has no usable state value. A call to states() for an entity ID that does not exist also returns the text unknown. |
Confirm that the entity exists and that its ID is spelled exactly correctly. |
unavailable |
The entity cannot provide a state at this moment. The device, service, or integration may be unreachable or not set up. | Check power, connectivity, integration setup, and system logs. |
has_value('entity_id') is false |
The entity is missing, or its state is unknown or unavailable. |
Branch to an explicit fallback instead of assuming a value. |
Home Assistant’s state-object documentation defines unavailable this way: “The entity cannot provide its state right now.” It gives an unreachable device or service and an integration that has not been set up as examples.
#1 Best Overall
- Home Assistant provides a professional and reliable platform for home automation, designed to run continuously 24/7.
- Powered by a 64-bit Quad-Core Cortex-A53 processor, delivering smooth and efficient performance for smart home automations.
- Includes 4GB SDRAM for reliable multitasking and 64GB eMMC
- Features a Mali-450 MP2 GPU for responsive visual interfaces, housed in a compact 85 × 85 × 15mm (3.35" × 3.35" × 0.59") design that fits easily in any space.
- Typical power consumption is under 10W, with fanless operation for quiet performance suitable for any room in your home.
What unknown means
No state value is known
An entity is unknown when Home Assistant does not have a state value it can use. This does not necessarily identify why the value is missing. The device may not have supplied an initial reading, an integration may not have produced one yet, or a template may have no result to publish.
A missing entity ID can also return unknown
The template function states('entity_id') is deliberately forgiving. If the entity ID does not exist, it returns the string unknown rather than raising an exception. Therefore, seeing unknown in a template does not prove that a real sensor reported an unknown measurement. Check the entity registry and spelling first.
For example, this call returns unknown if the ID is absent:
{{ states('sensor.outdoor_temperatur') }}
The typo in outdoor_temperatur is enough to produce that result. Use Settings > Tools > States to copy the exact entity ID instead of typing it from memory.
Rank #2
- Custom fit design provides a snug and secure hold for your compatible with Home Assistant Green, ensuring stability and easy access at eye level.
- Space-saving wall installation helps declutter surfaces by moving your smart home hub off counters and onto the wall for a cleaner setup.
- Durable construction crafted for reliable long-term use with quick and straightforward mounting on various wall surfaces.
- Sleek minimalist style complements modern home aesthetics while keeping ports and displays accessible.
- This product is a third-party accessory designed to be compatible with Home Assistant. Our products are not affiliated with, authorized, or endorsed by it and are mentioned for compatibility purposes only.
Prefer the function form when an entity might be missing
Function syntax is safer than dotted attribute access when an entity may not exist. states('sensor.temperature') returns text, including unknown for a missing ID. By contrast, an expression such as states.sensor.temperature.state can fail when that entity is not present. The function form also makes it easier to test the result before using it.
What unavailable means
The entity cannot provide a state now
unavailable indicates a present inability to provide the state, not a particular root cause. Home Assistant may be unable to reach the physical device, a cloud or local service may be unreachable, or the integration that owns the entity may not have been configured successfully.
Do not interpret every unavailable sensor as proof that its device is offline. A service outage, expired credentials, a failed integration setup, or a temporary startup delay can produce the same label.
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
Startup and restored entities
Home Assistant can restore registered entities as unavailable while integrations load. This lets other parts of the system reference the entity immediately, even though the integration has not yet supplied a live value. In this documented restored-entity case, the entity includes a restored attribute. That attribute is a clue about startup or setup timing; it does not mean that every unavailable entity is restored.
Rank #3
- [Multi-Protocol Hub with Matter Bridge] The Aqara Hub M200 is a versatile smart hub that supports multiple advanced features, acting as a Matter Controller, Thread Border Router, and Matter Bridge. It integrates third-party devices into the Aqara Home app. With advanced Matter bridging functionality, it syncs Aqara-exclusive features with ecosystems like Home Assistant, Apple HomeKit, Alexa, and Google Home for seamless integration. Supports up to 40 Aqara Zigbee devices and 40 Thread devices.
- [Smart IR Blaster with Feedback and Learning] The 360°IR blaster not only sends commands but also provides accurate status updates by detecting traditional remote use. It connects IR air conditioning units to Matter, functioning as an AC thermostat when paired with an Aqara Temperature and Humidity Sensor. (Note: Only one AC device can be exposed to Matter. Functionality may vary based on the Matter integration app. For Apple Home exposure, use Matter integration instead of HomeKit.)
- [Wired & Wireless Connectivity with PoE Support] Enjoy flexible setup with dual-band Wi-Fi (2.4/5 GHz) using advanced WPA3 security, and Power over Ethernet (PoE), making the M200 a versatile PoE Ethernet Smart Home Hub. The USB-C port supports mini-UPS or power bank connections for uninterrupted operation, ensuring your energy-saving and security automations stay online. (*2A USB power adapter is not included. )
- [Home Automation and Alarm System] Works with all Aqara devices to create a comprehensive, smart home automation system. The Aqara Hub M200 is equipped with a built-in speaker that can be used in a variety of ways: security alerts, doorbell, alarm clock, and custom audio messages. (** 𝐍𝐨𝐭 𝐭𝐡𝐢𝐫𝐝-𝐩𝐚𝐫𝐭𝐲 𝐙𝐢𝐠𝐛𝐞𝐞 𝐝𝐞𝐯𝐢𝐜𝐞𝐬)
- [Local Automation for Reliable Performance] Supports local execution of automations for Zigbee and Matter devices, ensuring smooth operation even without Wi-Fi or cloud access. Enjoy millisecond response times for a more stable and reliable smart home experience. (Some automation, such as cloud push notifications, will still require the cloud connection to be executed.)
How to diagnose either state
- Open the raw state. Go to Settings > Tools > States, search for the entity, and read the exact state value. A dashboard card may show a friendly name or hide the distinction.
- Verify the entity ID. Compare the ID with the one used in your template, script, or automation. Check domain, spelling, underscores, and device renames. If the ID is absent from the States tool, a
states()call will returnunknown. - For
unknown, identify why no value was produced. Check whether the entity is newly added, whether its integration has completed setup, and whether a template or helper has all of its source entities available. - For
unavailable, check the device or service. Confirm power, batteries, Wi-Fi or Ethernet, and any required hub. For cloud integrations, check the account connection and service status. - Read the logs. Go to Settings > System > Logs. Look for warnings or errors naming the integration, authentication, network connection, or referenced entity.
- Check startup context. If the entity has a
restoredattribute, allow the integration time to load and investigate setup failures if it never receives a live value. - Retest the exact operation. A dashboard refresh, template rendering, or automation trace can show whether the state becomes usable after the underlying issue is corrected.
Templates that handle missing and unusable values safely
Use has_value before displaying a reading
has_value('entity_id') is false when the entity is missing or its state is either unknown or unavailable. It is a good guard when a template needs an actual value:
{% if has_value('sensor.outdoor_temperature') %}
It is {{ states('sensor.outdoor_temperature') }}°C outside.
{% else %}
The outdoor sensor is unavailable.
{% endif %}
This check intentionally treats unknown and unavailable alike. If your message or logic must distinguish them, compare the exact state strings:
{% set state = states('sensor.outdoor_temperature') %}
{% if state == 'unknown' %}
No temperature value is known.
{% elif state == 'unavailable' %}
The temperature sensor cannot be reached right now.
{% else %}
It is {{ state }}°C outside.
{% endif %}
Convert text to a number only after deciding on a fallback
The return value of states() is text. Arithmetic therefore requires conversion, for example | float. Home Assistant documentation also shows a fallback such as | float(0) to avoid a conversion error:
Do these 3 things before closing this tab:
1Scan for outdated or missing drivers - takes under a minute2Clear out junk files and repair common Windows errors3Fix the driver behind crashes, sound loss and screen glitches{{ states('sensor.power') | float(0) }}
That filter does more than suppress an error: it makes the result numerically equal to zero when the input is nonnumeric, including an unusable state. Zero may be a sensible display fallback, but it can be dangerous in control logic. A zero power reading, zero temperature, or zero water level could trigger an action that should wait for a real measurement.
Rank #4
- 💡 EASIEST WAY TO GET STARTED WITH HOME ASSISTANT - With Home Assistant already installed, it only requires plugging the included power supply and Ethernet cable to get started.
- ✅ OFFICIAL - This official Home Assistant hardware is built and supported by Nabu Casa, the team driving the development of Home Assistant.
- 🏡 DESIGNED FOR THE HOME - The small, fanless, and silent design packs a quad-core processor, 32GB of storage, and 4GB of RAM.
- 📱 ONE HUB TO CONTROL THE WHOLE HOME - Cut down hub and app clutter and control your whole home from Home Assistant Green.
- 🤖 AUTOMATE EVERYTHING - Make all the devices in your home work in harmony - have your lights dim when you start watching a movie, or turn off your heat when you’re away from home.
For decisions, guard first and choose an explicit unusable path:
{% if has_value('sensor.power') %}
{{ states('sensor.power') | float }} > 100
{% else %}
false
{% endif %}
Use a default only when that default is correct for the sensor and the consequence of acting on it is understood.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Automation conditions and triggers
State conditions require exact values
A state condition compares the entity’s state with the value you specify. To test for either special state, enter the exact text unknown or unavailable. An unavailable entity will not pass a condition that expects on, off, or another ordinary value.
Recommended Free Tools
If your goal is to detect any usable state, a template condition using has_value is usually clearer:
Best Value
- EASIEST WAY TO GET STARTED WITH HOME ASSISTANT: With Home Assistant already installed, it only requires plugging the included power supply and Ethernet cable to get started
- DESIGNED FOR THE HOME: The small, fanless, and silent design packs a quad-core processor, 32GB of storage, and 4GB of RAM
- ONE HUB TO CONTROL YOUR WHOLE HOME: Simplify your smart home with HA70. Built with official Home Assistant OS and a professional Zigbee coordinator, it brings local control, powerful automation, and seamless device management into one compact hub
- AUTOMATE EVERYTHING: Make all the devices in your home work in harmony - have your lights dim when you start watching a movie, or turn off your heat when you're away from home
- YOUR HOME, YOUR DATA: Your home's data will be kept in the home on your HomeAssistant. You can easily view, share, and export that data anywhere you want
condition:
- condition: template
value_template: "{{ has_value('sensor.outdoor_temperature') }}"
Numeric-state conditions stop when values are unusable
A numeric-state condition does not pass while the measured entity is unknown or unavailable. The same applies to an entity used as the threshold. For example, a condition comparing a room temperature with a threshold sensor cannot evaluate if either value is unusable. Check both entities when a numeric condition unexpectedly fails.
Reconnects may not satisfy a prior-state trigger
State-change triggers can require a specific previous state. Suppose a light was unavailable and later reports on. The transition is from unavailable to on, not from off to on. A trigger that explicitly requires off as the prior state therefore will not fire on that reconnection. If reconnection should count, design the trigger and conditions to account for the unavailable-to-live transition.
Common cases and the right first response
A sensor card shows unknown
- Open Tools > States and confirm the entity exists.
- Copy the exact entity ID into the card or template.
- Check whether the integration has produced an initial reading.
- If a template sensor is involved, inspect every source entity it references.
A device entity shows unavailable
- Verify mains power or battery charge.
- Check the device’s network, radio, or hub connection.
- Confirm that the associated service account is connected.
- Read System > Logs for integration errors.
The entity is unavailable only after a restart
Allow integrations to finish loading and inspect the entity’s attributes. A restored attribute indicates the documented restored-entity startup case. If the state remains unavailable, treat it as a setup or connectivity problem and use the logs to identify the failing integration.
Quick wins for a faster PC:
Scan for outdated or missing drivers - takes under a minuteDriver Scan →Clear out junk files and repair common Windows errorsFree Scan →An automation behaves differently after an outage
Review both the trigger’s previous-state requirement and every condition. A reconnect may not pass a trigger requiring off, and a numeric condition will not pass until all relevant values are numeric and available.
Quick Recap
A practical checklist
- Read the raw state in Settings > Tools > States.
- Confirm the entity ID exists and is spelled correctly.
- Remember that a missing ID passed to
states()also returnsunknown. - For
unknown, investigate why no value has been produced. - For
unavailable, check power, connectivity, service access, and integration setup. - Inspect Settings > System > Logs for warnings and errors.
- Use
has_valuebefore displaying, converting, or acting on a state. - Use
| float(0)only when substituting zero is safe and intentional. - In automations, account for exact state conditions, unusable numeric values, and reconnect transitions.
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

