Skip to content
Language:en

HTML viewer

Paste HTML and CSS and see the page rendered live, on desktop, tablet or phone width.

Preview width

Scripts are blocked and external files are not loaded: the preview only shows your HTML and CSS.

Runs entirely in your browser. Your files never leave your device.

About this tool

Received an HTML email template, a snippet from a tutorial or an exported page, and want to see what it looks like? Paste the code on the left and the rendered page appears on the right as you type. Add CSS in the second tab to style a fragment, or paste a complete document with its own head and styles.

Switch the preview to tablet or phone width to check a responsive layout, re-indent messy markup with Format, and download the result as a single .html file. The preview runs in a locked sandbox: JavaScript in the code never executes and nothing is loaded from other sites, so even an unknown file is safe to look at. Your code stays in this browser.

How it works

  1. Paste or type HTML in the first tab.
  2. Optionally add CSS in the second tab.
  3. Choose the preview width.
  4. Format or download the page if needed.

A fragment is wrapped in a minimal page; CSS from the second tab is added at the end of the head. The draft is kept in this browser only, so it is still there when you come back.

Worked example

A newsletter template built in tables at 600 px wide: paste the HTML, switch the preview to phone width and see whether the columns stack or overflow. Format re-indents the code so you can find the cell that breaks.

For a snippet from a tutorial, paste the HTML in the first tab and its CSS in the second to see the result without creating any file.

Good to know

  • Images with relative paths will not show; use full URLs or data URIs to preview them.
  • Email clients ignore much modern CSS; inline styles are the safest for newsletters.
  • Download the result as one .html file to send a static mock-up to someone.

Frequently asked questions

Why does my JavaScript not run?
On purpose. The preview frame blocks every script, so pasting unknown code can never run anything. Use it to check markup and styles.
Why are my images not showing?
The preview does not fetch files from other websites, to keep what you paste private. Images embedded as data URLs are shown.
Is my HTML sent anywhere?
No. Rendering happens in your browser, and the draft is only saved in this browser’s local storage.
Can I test a mobile layout?
Yes. Pick the 375 px width for a typical phone or 768 px for a tablet; media queries in your CSS react to that width.