Skip to content

HTML Viewer Online

Paste HTML or open an .html file to see the rendered page instantly.

HTML code

Tab inserts indentation. Press Escape, then Tab, to move focus out of the editor.

Rendered page

Preview width

How to view HTML online

  1. Paste HTML code into the left panel, click Open .html file, or drag an .html file onto the viewer.
  2. The rendered page appears on the right immediately and updates as you edit.
  3. Switch between Desktop, Tablet and Mobile widths to check the layout, or open the page in a new tab.

An HTML viewer for code and files

Sometimes you just need to see what a piece of HTML looks like: an email template from a colleague, a saved web page, an export from another tool or a snippet from documentation. This HTML viewer online renders it instantly, side by side with the source, without creating a file or opening a local server.

The preview is a real browser rendering in a sandboxed frame, so CSS, web fonts from CDNs and JavaScript behave as they would on a live page — while staying isolated from this site. Files are read locally and never uploaded.

Features

  • Open .html and .htm files or drag and drop them; paste code from anywhere.
  • Live preview with desktop, tablet (768 px) and mobile (375 px) widths.
  • Tidy the code with one click using the built-in formatter.
  • Copy or download the HTML, or open the rendered page in its own tab.

Common uses

  • Check an HTML email before sending it, including how it looks on a phone-sized screen.
  • Inspect an exported report or saved page that your computer opens as source code instead of a web page.
  • Preview a snippet from a tutorial or Stack Overflow answer before using it.

Related HTML tools

Want to write HTML, CSS and JavaScript in separate tabs? Use the online HTML editor, or the HTML compiler to run scripts and read console output. If the code is hard to read, clean it up with the HTML formatter; if you only need the words, the HTML to text converter extracts them.

Frequently asked questions

How do I view an HTML file online?
Click Open .html file or drag the file onto the viewer. The page is rendered immediately next to its source code. The file is read in your browser and is not uploaded anywhere.
Is it safe to view HTML from an unknown source?
The page is rendered in a sandboxed frame with an isolated origin, so its scripts cannot read this site's data, your cookies or navigate this page. As always, be careful with content you don't trust, for example don't enter passwords into forms it contains.
Why are images missing in my preview?
Images and stylesheets referenced with relative paths (images/photo.jpg) live next to the original file on your computer and are not available to the viewer. Absolute https:// URLs and inline data: images display normally.
Can I see how the page looks on a phone?
Yes. Switch the preview between Desktop, Tablet (768 px) and Mobile (375 px) widths to check how the layout responds.
Can I edit the HTML in the viewer?
Yes, the code is editable and the preview updates as you type. For writing HTML, CSS and JavaScript in separate tabs, use the online HTML editor.