Unable to connect to Home Assistant locally after enabling https

I have successfully enabled remote secure connection by following the guide " Effortless encryption with Let’s Encrypt and DuckDNS".

I can connect both remotely (https://xxx.duckdns.org) and locally (https://192.168.1.xxx:8123) from my Android mobile phone using Chrome. However when I try to connect locally from my local PC (I tried both Chrome and Edge in Windows) after entering the correct credentials I get the following prompt.

image

Any workaround on this issue?

Use http locally… You won’t be connecting remotely from anything on 192.168.1.xxx
You really need to use a reverse proxy to do this properly anyway,
Does your router support NAT loopback?

Thank you David for your suggestion.

I have succeeded to connect from the local LAN to https://192.168.1.100:8123 by using my mobile phone (as mentioned previously) and a Linux virtual machine running on my local PC. My problem is that I the connection is refused when using Windows on my local PC. I tried both Chrome and Edge, cleared cache but I still get the same error message.
How do you explain this?

P.S. Unfortunatelly my router does not support NAT loopback.

Edit your windows hosts file

C:\Windows\System32\drivers\etc\hosts

Add an entry
192.168.1.100 xxx.duckdns.org

On recent windows versions, you won’t be able to save, so save to documents, then copy it over to
C:\Windows\System32\drivers\etc\

Look at using a reverse proxy.

For some reason I managed to connect from the local Windows PC by entering https://xxx.duckdns.org:8123/ :slight_smile:

Looks strange because I am using port 443 for outside connections which is forwarded to 8123 by the router. Anyway, issue fixed.

Thank you all for your support!

Yes, this entry solved the problem! Then I need to use the xxx.duckdns.org with the internal tcp port, 8123 in this case.