I used DuckDNS for ages to access Home Assistant but it was flakey. I use Google Assistant so I need external access.
Nginx was the real bastard, it made my head hurt every time I used it. So eventually I gave Cloudflared a go.
I followed a blog and managed to get it working the free, with a free domain.
Until a couple of weeks ago. It just stopped working. Thanks to a Reddit post I worked out that it was because my free domain used .ga and that was taken down because it was used by hackers and tricksters and odious people who were up to no good.
So I’ve bought a .com address for 5 years for around £0.65 a month through Cloudflare themselves. It was easy to set up and seems to be pretty solid, although I’ve only had it a couple days.
Try out caddy next time instead of nginx. Long as you can get the port open its braindead simple.