Online HTML Editor: Free With Live Preview
This is an HTML editor with a live preview for writing web code. If you write in Markdown, use Markdown Editor or Markdown to HTML Converter. This online HTML editor shows a live preview, like a simple CodePen in your browser. Write HTML, CSS and JavaScript in separate panes, and see the result update as you type. It is great for learning web code, testing snippets and building small pages.
Online HTML Editor
Write HTML, CSS and JavaScript and see the result live. Free, no signup, works offline once loaded.
How to use the Online HTML Editor
- Type or paste your HTML in the HTML tab, and your styles and scripts in the CSS and JavaScript tabs.
- Watch the preview update automatically, or untick Auto-run and press Run (Ctrl+Enter).
- Check the Console under the preview for console.log output and JavaScript errors with line numbers.
- Pick Phone or Tablet under Preview to test responsive layouts, or Open in new tab to see the page full size.
- Start from a template such as Landing page, To-do app or Contact form, or open an existing HTML file.
- Click Download HTML to save one file with everything inside, or Download CSS and JS separately for three files.
Features
- Separate HTML, CSS and JavaScript editors with syntax highlighting, line numbers, active line and bracket matching.
- Auto-closing tags and brackets, Tab indenting and a Format code button.
- Live preview that updates as you type, or manual Run with Ctrl+Enter.
- Built-in console that shows logs, warnings, errors and unhandled promise rejections.
- Responsive preview at phone, tablet and full width, plus full screen and open in new tab.
- 7 starter templates: blank, hello world, profile card, landing page, to-do app, canvas animation and contact form.
- Opens HTML files and splits their style and script blocks into the right tabs.
- Downloads a single HTML file or separate HTML, CSS and JS files.
- Light and dark themes, 4 font sizes, 4 layouts, and autosave in your browser.
Frequently asked questions
Is this HTML editor free?
Yes. It is free with no signup and no limits, and your code is not uploaded anywhere.
Is my code saved?
Yes. It autosaves in this browser on this device. Download the HTML file to keep a permanent copy or move it to another computer.
Can I use external libraries?
Yes. Add a script or link tag with a CDN address in the HTML tab, for example for a CSS framework or a chart library. You need an internet connection for those to load.
Is the preview safe?
The preview runs in a sandboxed frame, so your code cannot change this page or read its data.
Can I use it to learn HTML and CSS?
Yes. Start with the Hello world template, change the text and colors, and see the result instantly. The console helps you find JavaScript mistakes.
Does it support PHP or Python?
No. It runs HTML, CSS and JavaScript only, because those run directly in your browser.
See also: HTML Minifier, Markdown to HTML, JSON Formatter, Color Picker, Online Notepad.
Write HTML with live preview
How to use it
- Type HTML in the HTML pane.
- Add styles in the CSS pane.
- Add scripts in the JS pane.
- Watch the preview and download.
More questions
Is it like CodePen?
Yes, a simple version that runs in your browser.
Can I save my code?
Yes. Download your HTML, CSS and JavaScript files to keep or publish.
Is it good for beginners?
Yes. Changes show in the live preview right away, which makes it easy to learn HTML.
Related tools: Web Design Software, HTML Formatter and Minifier, Markdown Editor.