A device already exists with that name

I am so tired of dealing with this issue. Multiple times we’ve had to log out our mobile devices because HA and the mobile device are out of sync on location and those automations stop working. In the past I’ve resolved this by logging out and logging back in again.

Now I’m getting this error about a duplicate name and I don’t know how to quickly resolve this without modifying all of my automations again. It’s happening on both of our iOS devices. Logging with the same device should not cause this headache over and over again.

Ok, I finally found a more definitive reference on how to fix this and working so far.

  • Open HA on desktop.
  • Go to Integrations.
  • Go to Mobile App.
  • Delete the mobile device.
  • Kill the HA app on phone.
  • Reopen HA app and login again.

Appears this restores everything. Will verify loocation updates later on before I mark this as solved.

Hi Joe, you are not using multiple mobile devices with the same name by accident?

Nope. Just two devices. Same ones we’ve always used.

Are you sure about that?

Check the Developer tools → STATES or entities for something in the line of ‘sensor.iphone_xxx’ to see whether they are different.

I know this is an old discussion, but the same thing just happened to me. I logged out of the HA app on my iPhone and logged back in and it asked me to name the device. I thought well, that’s weird, shouldn’t it know this is the same device? I typed in the same name and now I have two devices in HA with exactly the same name.

The old device, which has all my automations associated with it is no longer updating. (battery level, etc)
The new device is updating but has no automations associated. I’m about to try the steps Joe outlined above in hopes of not having to update very single automation.

Check your entities for *_2 named entries.

Yeah. All new entities. Oh well. I had to fix about a dozen automations, but it’s all sorted out now. Note to self, never log out.