When this occur do other website work?
How long you test before wifi connect/disconnect? (Is it possible HA temporary not connected to internet and just conicidence/perfect timing wifi dis/reconnect fix)
I would try disabling your internal connection url in the app configuration, to see if that makes any difference. It might indicate where in your network setup the problem exists.