home-assistant / home-assistant/iOS

Multi-server regression: all saved servers lose authenticated user state and stop loading (~30 servers)

Open
#5,595 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
Swift
Stars
2.4k
Forks
520
Avg merge
7h 27m
Merged PRs (30d)
264

Description

### Describe the bug

I have a large multi-server setup with almost 30 Home Assistant servers configured in the iOS Companion App.

Normally, the server list connects automatically and shows my Home Assistant username underneath each server name. When the problem occurs, all saved servers still appear in the list, but the username disappears from underneath every server at the same time. From that point, none of the servers load successfully.

Selecting a server appears to start opening it, but the app then hangs/stalls and the frontend never finishes loading.

This does not appear to be a Home Assistant server or network connectivity problem:

- The servers themselves are reachable and working.
- The issue occurs across many different HA servers simultaneously.
- It reproduces on Wi-Fi and when Wi-Fi is disabled / using cellular.
- Previous Companion App versions did not exhibit this behavior with the same server list.
- Automatic Server Switching is disabled.

The strongest observable indicator is the server list itself:

**Working state:** server name + authenticated username shown underneath.

**Broken state:** server name only, with the username missing for all servers, and none of the servers will load.

This looks like a global failure to restore/load saved server authentication/session state rather than a connectivity failure to individual servers.

### Versions affected

- Home Assistant Companion App 2026.8 (App Store)
- Home Assistant Companion App 2026.9 (TestFlight)

The same behavior is present in both.

### Steps to reproduce

The problem is intermittent, but in my setup:

1. Configure a large number of Home Assistant servers (approximately 30).
2. Open or resume the iOS Companion App.
3. Normally, usernames appear underneath all server names and the servers load correctly.
4. In the broken state, all usernames disappear from the server list simultaneously.
5. Select any server.
6. The server view starts opening but remains stuck and does not finish loading.
7. Switching between Wi-Fi and cellular does not resolve it.

### Expected behavior

Saved server sessions/authentication should be restored consistently on app launch/resume. Each server should show its authenticated username and open normally.

### Actual behavior

All saved servers remain visible, but the authenticated username/profile information disappears for every server simultaneously. None of the servers then load successfully.

### Additional context

This started only with the newer Companion App releases; the same large list of servers worked correctly in earlier versions.

Because all servers fail together and the username/profile state disappears from the server list itself, this may be related to multi-server session initialization, authentication state restoration, ServerManager lifecycle, or app resume/launch handling rather than per-server connectivity.

Potentially related issues/areas include recent multi-server and lifecycle regressions such as #5064, #5234, #5278 and reconnect/session handling changes, but this specific symptom — all configured servers simultaneously losing the displayed authenticated username while remaining present in the server list — seems distinct.

I can provide Companion App logs captured immediately after launch in the broken state if useful.

Contributor guide

Open the contributing guide

Research direction

Start with app launch/resume handling and the ServerManager lifecycle, focusing on multi-server session initialization and authentication state restoration. Reproduce the intermittent broken state with a large server list and capture Companion App logs; done means all saved servers retain their usernames and open normally after launch or resume.

Written by the indexing model from the issue text.

Assessment

Tech stack
ios, swift
Domain
authentication, mobile
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.