[solved] With login on new device no connection through cloud possible on local network

I ran into the following problem:

I’ve added the android companion app through play store on a new device (tablet) after running the companion app on different mobile devices without problems using home assistant cloud connection.
After this worked initially fine for a couple of minutes suddenly ALL companions apps stopped working through home assistant cloud connection.

I’ve fixed this by going to settings → companion app → selecting my home under settings & devices and setting up my home network and internal connection URL. Before, this was empty and worked fine.

I’ve ran into this a week earlier and at that time couldn’t find the fix and used a backup to get it back to working normally.

Although i’ve found a fix now, it still puzzles me why this happened. In the logs around this time i did find the following (X200 being the new device):

Logger: homeassistant.components.http.ban
Bron: components/http/ban.py:136
integratie: HTTP (documentatie, problemen)
Eerst voorgekomen: 6 december 2025 om 21:34:01 (5 gebeurtenissen)
Laatst gelogd: 6 december 2025 om 21:34:11

  • Login attempt or request with invalid authentication from localhost (127.0.0.1). Requested URL: ‘/auth/token’. (Home Assistant/2025.11.4-19134 (Android 14; SM-X200))
  • Login attempt or request with invalid authentication from localhost (127.0.0.1). Requested URL: ‘/api/websocket’. (Mozilla/5.0 (Linux; Android 14; SM-X200 Build/UP1A.231005.007; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/142.0.7444.102 Safari/537.36 Home Assistant/2025.11.4-19134 (Android 14; SM-X200))

I have a simple setup with home assistant running on an odroidN2+ which is on the same network as all my other devices. I have a nabu casa cloud subscription. I do also use pihole but stopped this to test it after getting the connection error without resolving the issue.

Any thoughts on why this happens?

Also, since this problem i also cannot access home assistant from outside my network.

I get: error 403: forbidden. I checked again if connecting through HA Cloud service was enabled and it is.

Check if you have ip_ban_enabled & login_attempts_threshold in your configuration.yaml file. If you do, chances are your IP is listed in a separate ip_bans.yaml file. Read here on how to deal with it

Great, many thanks!! This was some old yaml in there from the time I had setup external connection through nginx etc. Removed it to remove my problems.