In order to do this, I create a new page (say test.aspx) on a page library, and edit this page by opening it directly from a text editor in my PC, and then wipe everything and start from scratch editing the html of this page. I don't even have any server code on the page, but I keep the aspx extension because html uploads are forbidden in my farm.
What could possibly go wrong?
Wiping everything is not a good idea - as @Zakir HC mentioned, you loose the MasterPage Features. That could increase the efforts to migrate and maintain the solution.
Additionally: If you modify the page like that the page will be stored in the database and could increase the load (possible but unlikely).