Home/Tools/Text & developer utilities
HTML Tester
Type on the left, see it on the right. The preview is sandboxed.
A scratchpad for HTML
Type markup on the left, see it rendered on the right. No file to save, no project to set up, no build step — which is exactly what you want when you are checking whether something works rather than building anything.
How the preview is isolated
Your code runs inside a sandboxed frame with a unique origin. It cannot read or change this page, cannot reach the storage of any site you are logged into, and cannot see anything outside its own frame. Scripts are allowed so that you can test them, but they are confined.
This matters because a live HTML preview is otherwise a straightforward way to run arbitrary code on a page. The sandbox is what makes the tool safe to use with code you found somewhere and have not read carefully.
What works here
- HTML, CSS and JavaScript, inline or in <style> and <script> tags.
- External resources such as fonts and images from a URL, subject to the other site allowing it.
- Full documents if you want them — a complete page with doctype and head renders fine.
What does not work: anything needing a server, anything needing cookies from another origin, and anything relying on local files.
How to use it
- Edit the code on the left. The preview updates as you type.
- Turn off live updating if a half-finished tag is making the preview jump about, then use Run.
- Paste a snippet you want to understand and take it apart a line at a time.
- Nothing is saved. Copy anything you want to keep before you close the tab.
Common uses and tips
- Checking a snippet from documentation or an answer before putting it into a real project.
- Teaching and learning, where seeing the result change as you type is the whole point.
- Testing an email template's HTML, with the caveat that email clients render far more restrictively than a browser — this shows you the best case, not what Outlook will do.
- Debugging by subtraction. Paste the broken thing, then delete half. Repeat until it works. It finds the problem faster than reading does.
- Checking accessibility basics — heading order, alt text, label association — on a small fragment.
Questions people ask
Is my code sent to a server?
No. It is rendered in your own browser, in a sandboxed frame on this page.
Can I run JavaScript?
Yes. Scripts run inside the sandbox, which has its own origin and cannot reach this page or any site you are logged into.
Is my code saved?
No. Closing or refreshing the tab loses it, so copy anything you want to keep.
Can I test an email template?
You can see how a browser renders it, but email clients are far more restrictive. Treat this as the best case rather than a representative one.
Why does the preview flicker while I type?
Because it re-renders on every keystroke, including half-finished tags. Turn off live updating and use Run instead.