Skip to content

WebRTC autoplay blocked in Frigate addon unless "Autoplay videos" is enabled #6578

@sbraz

Description

@sbraz

Home Assistant Android app version(s): 2026.3.2

Android version(s): 16

Device model(s): Pixel 8a

Home Assistant version: Core 2026.3.2 / Frontend 20260312.0

Last working Home Assistant release (if known): N/A

Description of problem, include YAML if issue is related to notifications:

The Frigate app switches from MSE to WebRTC when the user enables the microphone for 2-way audio. This creates a new video element with a new PeerConnection. On the Android companion app, the video goes black while audio continues working. The same flow works on iOS, and on the same phone with Firefox mobile or Chrome.

The cause is mediaPlaybackRequiresUserGesture, which defaults to true. I believe Android WebView uses transient user activation, which expires before the async WebRTC setup completes (getUserMedia, SDP exchange, ICE). The new video element then fails unmuted autoplay.

Changing this setting ("Autoplay videos") works around the issue:

settings.mediaPlaybackRequiresUserGesture = !this

It's also possible to make this work by muting audio right after clicking the mic button: video starts muted so it plays properly.

I attempted to push a workaround that leveraged this behaviour to Frigate but they consider this an HA companion app issue:
blakeblackshear/frigate#22494 (comment)

Screenshot or video of problem:

Image

Additional information:

Original Frigate issue: blakeblackshear/frigate-hass-addons#274

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions