I moved from standard Https with the duck DNS add-on, across to nginx today.
There’s so many threads on people having issues, that I wanted to just specify what I did to make it work.
Comment out the http section
Restart home assistant
Check you can connect internally
In router / firewall:
Remove existing port forwards
Add fowrading to the device running nginx on ports 80:80, 81:81, and 443:443
Install the mariadb addon
Install the nginx proxy manager add-on by Frenck
Follow the instruction in frencks gif
You should now have access internally over http and externally over Https.
I then had to go to Google console and update the address it uses to send commands to ha. Just had to remove :8123 from the middle of the URL. There may be places in your config where you also need to remove the :port part of the base url, for example in google text to speech.
All up and working in about 15 mins.