Https connection over the internet broken as of 2024.4.1

Hi,

I am a new user to home assistant (started around dec). I arranged access to my HA instance from the internet using a dynamic dns (ddns.net) and a letsencrypt certificate.

All worked fine, but yesterday i upgraded to 2024.4.1 (i use docker compose, so did a docker compose pull and than dock compose down and up again…). And when i try to access ha from the internet by Domainname.ddns.net:8123 it now shows
“unable to connect to home assistant \n retrying in XX seconds” with a “retry now link”
When access with localipadress:8123 from my local lan it still works

How can i troubleshoot?

Check if your certificate is not expired.

already checked. Certificate is fine.

and your external ip is still mapped correctly ?

yes, 100% sure of that. the same mapping (and certificate) is also used for domoticz which runs on the same raspberry pi. And that one works fine…

HA also worked before the upgrade. After i upgraded i noticed the error…

Check the HA logs.

Already did, cannot find any clues related to this issue:

2024-04-08 09:19:03.222 WARNING (MainThread) [homeassistant.components.ssdp] Could not set up UPnP/SSDP server, as a presentation URL could not be determined; Please configure your internal URL in the Home Assistant general configuration
2024-04-08 09:19:05.314 ERROR (MainThread) [homeassistant.components.sensor] Platform mqtt does not generate unique IDs. ID zwavejs2mqtt_0xec017be9_71-128-0-level already exists - ignoring sensor.unused_humptemp_unused_humptemp_battery_level
2024-04-08 09:19:07.971 ERROR (MainThread) [homeassistant.components.binary_sensor] Platform mqtt does not generate unique IDs. ID zwavejs2mqtt_0xec017be9_71-128-0-isLow already exists - ignoring binary_sensor.unused_humptemp_unused_humptemp_battery_islow
2024-04-08 09:19:07.973 ERROR (MainThread) [homeassistant.components.binary_sensor] Platform mqtt does not generate unique IDs. ID zwavejs2mqtt_0xec017be9_71-113-0-Smoke_Alarm-Sensor_status already exists - ignoring binary_sensor.unused_humptemp_unused_humptemp_smoke_alarm
2024-04-08 09:19:07.977 ERROR (MainThread) [homeassistant.components.binary_sensor] Platform mqtt does not generate unique IDs. ID zwavejs2mqtt_0xec017be9_65-48-0-Smoke already exists - ignoring binary_sensor.garage_rookmelder_smoke
2024-04-08 09:19:07.984 ERROR (MainThread) [homeassistant.components.binary_sensor] Platform mqtt does not generate unique IDs. ID zwavejs2mqtt_0xec017be9_65-113-0-Smoke_Alarm-Dust_in_device_status already exists - ignoring binary_sensor.garage_rookmelder_dust_in_device_status
2024-04-08 09:19:08.534 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.woonkamer_zwollelamp_electric_power_factor_value (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using native unit of measurement 'Power Factor' which is not a valid unit for the device class ('power') it is using; expected one of ['kW', 'W']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2024-04-08 09:19:08.556 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.woonkamer_tulplamp_electric_power_factor_value (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using native unit of measurement 'Power Factor' which is not a valid unit for the device class ('power') it is using; expected one of ['kW', 'W']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2024-04-08 09:19:08.578 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.boom_tuinverlichting_electric_power_factor_value (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using native unit of measurement 'Power Factor' which is not a valid unit for the device class ('power') it is using; expected one of ['kW', 'W']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2024-04-08 09:19:12.849 ERROR (MainThread) [homeassistant.components.binary_sensor] Platform mqtt does not generate unique IDs. ID zwavejs2mqtt_0xec017be9_65-48-0-Smoke already exists - ignoring binary_sensor.garage_rookmelder_smoke
2024-04-08 09:19:12.853 ERROR (MainThread) [homeassistant.components.binary_sensor] Platform mqtt does not generate unique IDs. ID zwavejs2mqtt_0xec017be9_65-113-0-Smoke_Alarm-Dust_in_device_status already exists - ignoring binary_sensor.garage_rookmelder_dust_in_device_status

First line in the error log

what do you mean?

I believe you have a device or application which uses UPnP/SSDP and is overtaking the port. Check your router logs too.

My “router” is a modem from my telco provider, on which i do not have access to the logs. Only a GUI. In that GUI i can see several extra services with an opened port by upnp, but none of them has 8123. according to that screen 8123 is forwarded to the local ip adress of the pi which has home assistant installed.

so all looking good over there…

Have you restarted your modem/router just to eliminate a possible conflict?

i just fixed it! It was indeed in the first error in the log, but a different solution…

I added the lines

homeassistant:
  external_url: "https://<domainname>:8123"
  internal_url: "https://<local_ip_adress>:8123"

to the config and after restart it now worked. The first error also gone

apparently this config change is needed after 2024.4.1 when accesssing by https over the internet

thankx for your help!

Happy you found the solution!!