Skip to content

Ingress closes add-on WebSocket connections on every 40s #6143

@felipecrs

Description

@felipecrs

Describe the issue you are experiencing

Hi, I'm having a really annoying issue while testing a new add-on I'm "developing".

On every 40 seconds, the WebSocket connection is closed.

Image

Is this a known issue? How to prevent that?

Cloudflare has a similar "issue" where dormant WebSocket connections are closed in 100 seconds.

I implemented a WebSocket keepalive mechanism (selkies-project/selkies#198) which "fixes" the problem for Cloudflare (I confirmed).

However, even lowering the heartbeat interval to something like 15s does not prevent the WebSocket from being closed on every 40s in the Home Assistant ingress.

Any feedback is appreciated.

What type of installation are you running?

Home Assistant OS

Which operating system are you running on?

Home Assistant Operating System

Steps to reproduce the issue

  1. Install my (WIP) Webtop add-on: https://github.com/felipecrs/webtop-hass-addon
  2. Start it and open its UI through ingress
  3. Keep it open for a while. Notice the connection will break after 40 seconds.

Anything in the Supervisor logs that might be useful for us?

No, there's nothing useful there from what I can tell.

System information

version core-2025.8.3
installation_type Home Assistant OS
dev false
hassio true
docker true
container_arch amd64
user root
virtualenv false
python_version 3.13.3
os_name Linux
os_version 6.12.41-haos
arch x86_64
timezone America/Sao_Paulo
config_dir /config
Home Assistant Community Store
GitHub API ok
GitHub Content ok
GitHub Web ok
HACS Data ok
GitHub API Calls Remaining 5000
Installed Version 2.0.5
Stage running
Available Repositories 2170
Downloaded Repositories 11
Home Assistant Cloud
logged_in false
can_reach_cert_server ok
can_reach_cloud_auth ok
can_reach_cloud ok
Home Assistant Supervisor
host_os Home Assistant OS 16.1
update_channel stable
supervisor_version supervisor-2025.08.3
agent_version 1.7.2
docker_version 28.3.3
disk_total 468.7 GB
disk_used 127.4 GB
healthy true
supported true
host_connectivity true
supervisor_connectivity true
ntp_synchronized true
virtualization
board generic-x86-64
supervisor_api ok
version_api ok
installed_addons Advanced SSH & Web Terminal (21.0.2), Studio Code Server (5.19.3), ESPHome Device Builder (2025.8.2), Mosquitto broker (6.5.1), Glances (0.21.1), Cloudflared (5.3.8), Nginx Proxy Manager (2.1.0), Hikvision Doorbell (3.0.22), Asterisk (5.3.1), Frigate Beta (0.16.0), Netdata (v2.6.3), Tailscale with features (0.25.0.12), Zigbee2MQTT (2.6.0-1), Webtop (0.1.0), Xpra (0.1.0)
Dashboards
dashboards 5
resources 4
views 10
mode storage
Network Configuration
adapters lo (disabled), enp2s0 (enabled, default, auto), docker0 (disabled), hassio (disabled), veth998203c (disabled), veth8d6d6f8 (disabled), veth8dbc95d (disabled), veth70e1787 (disabled), vethc320961 (disabled), vethd142d1f (disabled), veth25ae66b (disabled), veth98425d0 (disabled), vethba41f6a (disabled), veth4fb44c2 (disabled), vethe556973 (disabled), veth3d4f32e (disabled), veth2f6fb5a (disabled)
ipv4_addresses lo (127.0.0.1/8), enp2s0 (192.168.1.10/24), docker0 (172.30.232.1/23), hassio (172.30.32.1/23), veth998203c (), veth8d6d6f8 (), veth8dbc95d (), veth70e1787 (), vethc320961 (), vethd142d1f (), veth25ae66b (), veth98425d0 (), vethba41f6a (), veth4fb44c2 (), vethe556973 (), veth3d4f32e (), veth2f6fb5a ()
ipv6_addresses lo (::1/128), enp2s0 (fe80::8abc:dfb1:de66:b999/64), docker0 (fe80::4c90:4aff:feb6:3644/64), hassio (fe80::b48c:b9ff:fe87:d714/64), veth998203c (fe80::147f:58ff:fe9d:6ce6/64), veth8d6d6f8 (fe80::d0ab:8fff:fe73:2326/64), veth8dbc95d (fe80::1cde:92ff:fee4:11ce/64), veth70e1787 (fe80::2880:edff:fe46:96b7/64), vethc320961 (fe80::5040:e7ff:fe65:e286/64), vethd142d1f (fe80::98d4:99ff:fef4:b4ed/64), veth25ae66b (fe80::ccbb:3eff:fe42:7f7c/64), veth98425d0 (fe80::3035:26ff:fe5c:3ba3/64), vethba41f6a (fe80::acfb:c0ff:fea1:63b1/64), veth4fb44c2 (fe80::38eb:1ff:fe3e:c849/64), vethe556973 (fe80::983b:6fff:fe20:2b7b/64), veth3d4f32e (fe80::3d:6dff:fe10:f976/64), veth2f6fb5a (fe80::cfe:42ff:fe91:eff1/64)
announce_addresses 192.168.1.10, fe80::8abc:dfb1:de66:b999
Recorder
oldest_recorder_run August 15, 2025 at 11:02 PM
current_recorder_run August 29, 2025 at 1:45 PM
estimated_db_size 811.73 MiB
database_engine sqlite
database_version 3.48.0
Sonoff
version 3.9.2 (a7bce04)
cloud_online 1 / 6
local_online 1 / 1

Supervisor diagnostics

config_entry-hassio-8b5b34443b108b2dc71bf2f3232cfa91.json

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions