HA page sometimes takes forever to load on one device

Issue
Lately I’m facing a weird issue on my windows laptop. I use Chrome to connect to my ha instance.
Sometimes it loads forever. I can see the loading ha logo, but nothing happens. When I try it again seconds/minutes later it works fine again.
There are no errors or warnings in the logs pointing to this.

"Workaround"
This issue happens daily on that single laptop, but I remember that I had similar issues with my iPhone too. In this case it helped to switch to 4G and back to Wifi.
This is why I tried connecting my laptop to a hotspot of my phone today while it was loading forever (stuck). The page immediately poped up, but with the message “Reload lovelace”. Clicked it and works.

Details:

  • The laptop has no issues loading other webpages. The wifi signal is perfect.

  • I run hassio on a raspi 4 with ha 0.101.3. I use pihole and duckdns as addons. And it has a static local IP

  • the CPU usage of my pi4 seems fine. Idles around 10% with a few spikes up to 50%.

  • I use the same url in and outside my network. To achieve this pihole redirects the public url to the local IP.
    I think the issue has something to do with the redirection, but I ran out of ideas.

  • using a UniFi network

configuration of Pihole:

{
  "update_lists_on_start": true,
  "ssl": true,
  "certfile": "fullchain.pem",
  "keyfile": "privkey.pem",
  "interface": "eth0",
  "ipv6": true,
  "ipv4_address": "",
  "ipv6_address": "",
  "virtual_host": "myduckdns.duckdns.org",
  "hosts": [
    {
      "name": "myduckdns.duckdns.org",
      "ip": "192.168.0.2"
    }
  ],
  "log_level": "info"
}

Would appreciate any idea. Thanks!

I noticed that I have the same issue on another (faster) laptop too. It happens less often, but it happens too.

It loads forever and if I keep hitting the refresh button every few seconds it will load the page correctly.

Finally the solution for another issue that came up seems to have solved this issue too.

If you are facing the same issue with Chrome there might me a good chance that it has something to do with DoH.

You can find the solution here.