Skip to content

Make the Companion App capability-aware to guide users through Matter device setup #245

Description

@mkerstner

Problem statement

Adding a Matter device through the Companion App works — but it asks users to know things they should not have to know before they even reach the QR scanner.

The current flow (Settings → Devices & services / Connectivity → Matter → Add device → "No, it's new" → OS handover) contains no signal about whether the user's setup is actually ready for the device they are about to add:

  • Whether Home Assistant's Thread border router is reachable and IPv6 is functional
  • Whether this phone holds Home Assistant's Thread credentials — or whether the OS will silently hand a new Thread device the credentials of another ecosystem's network (Apple, Google), stranding it where Home Assistant can never see it
  • Whether the device the user is about to scan is likely certified, or will be rejected by strict attestation (Matter Server 9.0) with no path forward other than a global "allow test devices" flag and a server restart

When one of these preconditions is not met, the user only finds out after the OS-owned commissioning step fails — with a generic, platform-specific error ("Couldn't reach device" / "Unable to Add Accessory") that hides the real cause. Community support then starts with "which phone?", because Android and iOS fail at different moments with different wording.

Home Assistant knows the answers to most of these questions before handing over to the OS. It just doesn't ask them.

This effort is a continuation of OpenHomeFoundation/goals#19 (approachable Matter setup) and #31 (first-device wizard) and complements #177 and #237.

Community signals

Scope & Boundaries

In scope

  • A capability preflight in the Add Matter device flow on both Companion Apps, run before the OS handover, covering:
    • Home Assistant Thread network health (OTBR present, IPv6 functional) — surfaced as a readiness signal, not a blocker
    • Thread credential check against the phone's OS store
      • Android: name the preferred network via Play services (isPreferredCredentials / getPreferredCredentials, behind user consent) and warn deterministically on mismatch
      • iOS: detect whether Home Assistant's credentials are present/preferred by Border Agent ID; warn on "another network is preferred" even though it cannot be named
    • Offer "Sync credentials & continue" inline instead of requiring the user to find the sync action under Troubleshooting first
    • Consistent, platform-neutral failure explanations after the OS step, building on Show snackbar with troubleshooting link for Matter/Thread non-OK activity results home-assistant/android#6614 and extending the same information to iOS
    • Clear wording for the uncertified-device dead end, pointing to the actual resolution rather than a bare error
    • Reuse of the shipped first-device wizard (First device setup wizard focusing on Matter devices #31) as the flow's end state

Not in scope

  • Replacing the OS-owned commissioning UI (Play services / Apple accessory sheet)
  • Browser / frontend commissioning path (see separate opportunity)
  • Passive discovery of commissionable devices (see separate opportunity)
  • Other protocols than Matter / Thread (for now)

Foreseen solution

Risks & open questions

  • Platform asymmetry

Appetite

Medium - 1-2 cycles

Execution issues

No response

Decision log

Date Decision Outcome

Activity

  1. self-assigned this
    on Sep 28, 2026
  2. Hedda commented on Sep 29, 2026

    @Hedda

    For reference, there are a few other things also need to take into consideration when it comes to Matter commisioning today and the future:

    • Check that backups exist for recoverability before add devices
      • Fabric credentials live in the Matter Server's storage, and the Thread dataset lives in OTBR. Warn if neither is covered by a recent backup (as losing them risk orphans every device).
    • Wi-Fi and Ethernet Matter devices preflight (often forgotten next to Thread)
      • 2.4 GHz availability, band-steered or 5 GHz-only SSIDs, WPA3-only networks, guest networks with client isolation, and mDNS or IPv6 link-local across VLANs. The phone's current SSID is what the OS flow hands over.
      • Matter 1.4.2 added WiFi-only provisioning. Phone/tablet OS support for this is uneven at best, so the app should check capability before relying on it.
      • The phone/tablet must be on the same local network, not on remote access or a VPN over cellular. And an WiFi and Ethernet Matter device could not be put on a other VLAN (isolated network) from the Matter server and Home Assistant.
    • Thread details beyond "OTBR present"
      • Multiple Thread networks in the same house, and whether other border routers are Thread 1.4. Thread 1.4 standardises credential sharing, which could replace today's manual sync. Matter 1.4.2 requires network infrastructure managers to be Thread 1.4 certified.
      • Sleepy and ICD/LIT battery devices may need a button press to stay awake during commissioning. They also need check-in registration to succeed, or they look "added but dead".
    • BLE Proxy commisioning
      • BLE commissioning could be done via ESPHome Bluetooth Proxy (BLE Proxy) shipped with Home Assistant 2026.6 so is an option too.
        • Turn on ble_proxy on the Matter Server addon and put the device next to an ESPHome Bluetooth proxy instead of next to mobile device. This lets the Matter Server app commission directly over BLE through HA's own Bluetooth stack instead of using phone/tablets's Bluetooth. https://www.vome.io/kb/commission-with-a-bluetooth-proxy
          • Since this server-side BLE commisioning path skips the OS handover entirely, which avoids the Thread credential mismatch problem the issue centres on, the preflight could in the future maybbe recommend this as prefered path when a Bluetooth Proxy is in range? Another benefit path phone path could technically also leave an extra fabric behind (the OS vendor's own), which uses up one of the device's limited fabric slots.
          • This path will as well especially matters on phones/tablets that can not use the OS flow at all, like on for example Android devices without Google Play services (GrapheneOS/LineageOS, Huawei) or a stale Play services version. On those, server-side with a Bluetooth Proxy is really the only path.
    • NFC to commissioning, with two different paths. Optionally companion app should handle both cases. Perhaps "Tap to commission" and "Tap to read payload" flow options? Phones/tablets without NFC, and antenna placement, will also matter (pun intended).
      • NFC commissioning without Bluetooh, introduced in Matter 1.6 specification. Full NFC commissioning so device can be set up unpowered.
      • NFC commissioning with Bluetooth (instead of QR-code). Matter 1.4.1 already allowed the onboarding using an NFC tag instead of a QR code, but the commissioning itself still ran over BLE.
      • Add optional support for batch and pre-install setup? (would especially useful for installers adding multiple devices at once).
        • Matter 1.4.1 added support for multi-device setup (several codes in one package) and NFC pre-provisioning both argue for a queue-style flow rather than one device per run.
          • Benefit is multiple devices can be provisioned ahead and installed later, so flow maybe needs a "pending, not yet online" device state?
            • Guessing that the companion apps probably can not drive this alone, and will probably depend how Apple and Google expose this?
    • Joint Fabric (also introduced in Matter 1.6)
      • Joint Fabric lets multiple user-authorized controllers co-administer a single shared Matter network. This changes the ownership question: is HA the anchor or a participant? The app would need UX for joining, inviting, and showing which ecosystem administers what. It interacts with the existing "share to another ecosystem" (multi-admin) flow and fabric-slot counts.
    • Attestation and revocation beyond the test-device flag (also introduced in Matter 1.6)
      • Matter 1.6 adds partitioned certificate revocation lists. A specific certified device ID can later be rejected as revoked, so the app needs a distinct error for "revoked PID" versus "uncertified or test VID".
      • Devices still in development and DIY Matter firmware will keep hitting strict attestation. A per-device exception could perpas be better than the global flag plus restart? See DIY example projects such as https://github.com/DavidvtWout/esphome-matter and https://tasmota.github.io/docs/Matter/ Also remember that Home Assistant is a popular testing platform for Matter product developers).
  3. mkerstner commented on Sep 29, 2026

    @mkerstner
    MemberAuthor

    For reference, there are a few other things also need to take into consideration when it comes to Matter commisioning today and the future:

    Agree that we can expand this pre-flight check further, we just also need to start somewhere to further iterate upon.
    Based on recent discussions the items outlined in the refined flow could be a viable starting point - but not an exhaustive one of course.

    Ideally, users would never need to care about these detail screens as the checks are running in the background and only surface if needed or if someone is interested to get more insights. That's how we envision the pre-flight check and the overarching flow at the moment - which based on feedback sounds like a reasonable approach to start with. Of course, we can further expand on this idea but having a sound baseline to start with already reduces some of the friction our users currently encounter.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions