Are custom entity_id's kept in home-assistant_v2.db, if so is there a way to mass edit them?

Morning All,

I assume the custom entity_ids you create are stored in home-assistant_v2.db. Firstly is this assumption correct?

Secondly is there a way to mass change them rather than going one by one:


I spent a good part of last night changing 30+ sensors and then changing the relating scripts, automations and intent_scripts.

I know I can back up the .db but after a few months it gets massive and I’ve had my sd currupt on me in the past and I couldn’t just pop my back up .db file in (it didn’t work).

I take it the only way is to create a back up through the Front End, but again this can get massive over time.

So if there is a way to change them in bulk could you advise how? Also I have about 20 more I need to do (all Xiaomi sensors / switches with horrible names).

No. They are in the core.entity_registry file in the /config/.storage folder

This is not meant to be user editable but it is a plain text file. Be careful, make a copy of it and put it somewhere safe before you start mass find/replace.

1 Like

Great thanks, will have a look.