While older games use flash, which is no longer supported, game engines like unity, Monogame, Godot are able to export to a WebGL and even HTML5 (but still WebGL used) build of the game. These builds are able to be run in a browser. I don't think any renpy games can be run in a browser because they rely on their python interpreter alongside their built-in interpreter engine and unless the sight has a built-in interpreter (you basically would have to code your own website at that point) I don't think you can run python-based games in browser. If you mean games than play like a visual novel, well then that goes back to probably a flash or other game engine that just has said features built into the game as a game design choice.
running in WebGL mode is sub-optimal since it tends to lead to a lot more compiler errors, the game has a resource restriction and delay due to having to interface with the browser, etc. That is why unity games and newgrounds developed a "player" a special program that acts as a virtual browser or game console, but has direct access to computer resources and can run outside the browser, so it can support older formats such as ye olden flash type games. This also means that unity builds can avoid a buggy WebGL export and export for their desired system instead which is much more stable and reliable.