Zero dependencies · Open source · MIT license

The HTML Previewer
for Developers

Paste, format, highlight, and preview HTML — entirely in your browser. No install. No server. No nonsense.

Open Previewer Star on GitHub
0
Dependencies
MIT
License
3
Embed modes
12+
Features
Live Demo

See it in action

The app below is running live — not a screenshot. Open full screen →

What's inside

Everything you need

Live Preview
Render HTML in a sandboxed iframe or open full-page in a new tab.
Syntax Highlight
Colour-coded tags, attributes, values, and comments with one-click copy.
Auto Format
Beautify and properly indent messy HTML with one click.
Expand & Collapse
Clean up blank lines or compact code for a quick overview.
Import & Export
Load local .html files or URLs with drag-and-drop support, then download with a custom filename.
Deep Links
Share app#sample&preview or ?import=url — every action is URL-addressable.
System / Dark / Light
Three-way theme: follow OS automatically, or lock to dark or light — persists across sessions.
Auto-save Draft
Your work is automatically saved to localStorage so you never lose progress on a refresh.
Zero Dependencies
Pure HTML, CSS, and JS. No build step. No npm. No bundler. Ever.
FAQ

Frequently Asked Questions

No. HTML Previewer runs entirely in your browser with no account, no sign-up, and no server required. Open the app and start writing HTML immediately.
Yes. Clone the repository and open app/index.html directly in any modern browser — no internet connection or build step needed. The only online features are the import-from-URL fetch (which requires internet) and the Google Fonts / icon CDN.
Your draft is auto-saved to your browser's localStorage only. No data ever leaves your device — there are no analytics, no tracking, and no external requests that carry your code.
Yes. Use an iframe pointing to the hosted app. Three embed modes are supported: compact (?embed=1), demo (?embed=demo — interactive but no import/export), and read-only (?embed=readonly). See the README for full iframe code snippets.
Yes. HTML Previewer is MIT-licensed. You can fork, modify, and redistribute it freely. Contributions, issues, and pull requests are welcome on GitHub.
Ctrl/Cmd + Enter — run preview  |  Ctrl/Cmd + S — export to file  |  Ctrl/Cmd + K — toggle word wrap  |  Tab — indent 2 spaces  |  Shift + Tab — unindent  |  Escape — close modals
Quick Start

Up in 30 seconds

# Clone the repository
git clone https://github.com/MrLiPx/html-previewer.git
cd html-previewer

# Open directly in your browser — no server needed
open     app/index.html  # macOS
start    app/index.html  # Windows
xdg-open app/index.html  # Linux

# Deploy — Netlify, Cloudflare Pages & Vercel configs included