Can you figure out programmatically if an entity is considered "unmanageable" by HA?

See screenshot below - right most “Status” column.

It seems that certain sensors I’ve created and others which are natively created by HA (eg sun.sun) cannot have their area assigned. I noticed they are marked as “unmanageable”. Is it possible to detect this property in a template somehow? I want to filter them out when detecting entities that are missing area assignments :). Thanks!

They are entities that are made with yaml. You can most likely migrate all of those to the UI and manage them.

As for your question, no there is no way to template this with a 100% accurate representation.

This is the closest, however it will contain some things that were generated in the UI that don’t create config entries.

{%- for s in states if not config_entry_id(s.entity_id) %}
-  {{ s.entity_id }}
{%- endfor %}

Thanks a lot petro, I’ll try this.

Actually some of these are not made in yaml. Most of my yamp sensors are fine because I can add a unique id and then easily edit in the UI.

Some of these are built into HA (eg sun.sun and the backup state I think), and others are created via the UI Helpers (eg the Derivative and the Zone).

EDIT: I just tried and ya there are tons and tons of false positives (from my perspective, I’m sure the API is doing what it’s supposed to) so I’ll just harcode the entities I know cannot have areas assigned manually.