How to browse local HTML files with sandboxed Flatpak browsers?

You can either temporarily enable “Filesystem → All user files” in Flatseal for your browser, or start a simple http server to serve your files. For the latter, navigate to your files in a terminal and run python -m http.server 8000 --bind 127.0.0.1, then open http://127.0.0.1:8000/ in your browser.