[← README](../../README.md) · [Docs index](../README.md) · [The preview pane](README.md) # HTML pages, sandboxed An `.html`, `.htm` or `.xhtml` file is shown as a browser shows it, with its own styles, pictures and fonts, but inside a sandbox: no script runs and nothing is fetched from the web. A page you downloaded cannot run code or tell anyone that you opened it. ![The desktop app with index.html from ~/projects/website under the cursor: the preview shows the page with its own stylesheet (the green heading Rocket), Rendered and Source at the top right](../screenshots/previews-html.png) ## How to use it 1. Put the cursor on the HTML file and press **Space** or **F3**. 2. **Rendered** (the default) shows the page; **Source** shows the HTML, highlighted. 3. **Enter** opens the page in your browser, where its scripts do run. | Key | Desktop app | Terminal app | |---|---|---| | **Space** / **F3** | Shows or hides the pane | **F3** opens the HTML source in the built-in viewer | | **Enter** | Opens the page in your browser | The same | ## What is allowed, and what is blocked The page is loaded into a frame from disk, through the app's file protocol. The frame's `sandbox` allows no scripts, and the file protocol sends the page with a content security policy of its own, which the page cannot undo. The page keeps the file protocol's origin, so it can load the files beside it, but never the app's. | | In the preview | |---|---| | The page's HTML and inline `