Free Online HTML, CSS & JavaScript Editor

Free online HTML, CSS and JavaScript editor with live preview, console output and device widths. A CodePen-style playground that downloads as one .html file.

  • No upload, 100% private
  • Instant, in your browser
  • 100% free, no signup
Loading tool…
Read the complete guideHow to Build a Quick Web Prototype With HTML, CSS and JavaScript →

About the HTML CSS JS Editor tool

Trying out an idea for a web page should not require installing a code editor, a local server and a build tool. This online HTML, CSS and JavaScript editor gives you the familiar three-tab playground popularised by CodePen and JSFiddle, right in your browser, with no account and nothing to install.

Write your markup in the HTML tab, styles in the CSS tab and behaviour in the JavaScript tab. The tool combines them into one document, with the CSS in the head and the script at the end of the body, and renders it in a live preview that refreshes as you type. A console below the preview shows console.log output, warnings and uncaught errors with line numbers, so you can debug without opening developer tools. Device buttons let you check phone and tablet widths.

When you are happy with the result, the Download button saves everything as a single index.html file you can open anywhere or upload to a host. The preview runs in a sandboxed frame without access to this site, and your code stays on your device.

How to use HTML CSS JS Editor

  1. Start from the sample click-counter or press “Clear” for an empty playground.
  2. Switch between the “HTML”, “CSS” and “JavaScript” tabs and write your code.
  3. Watch the “Live preview” update, and use “Re-run” to restart the script.
  4. Check the console panel for logs and errors, and try the tablet and phone widths.
  5. Click “Download” to save the combined page as index.html.

Features

Three editor tabs

Separate HTML, CSS and JavaScript panes with Tab-key indentation, like CodePen.

Live preview with console

See the page and its console.log output, warnings and errors side by side.

Responsive checks

Preview at full width, 768px tablet or 375px phone width.

One-file export

Download a single index.html that contains your HTML, CSS and JS together.

Private sandbox

Code runs in an isolated frame in your browser and is never uploaded or stored.

When to use it

  • Prototype a UI component before adding it to a real project.
  • Reproduce a CSS or JavaScript bug in a minimal example to share with a teammate.
  • Practise DOM manipulation and event handling while learning JavaScript.
  • Try a code sample from a blog post or Stack Overflow answer without setting anything up.
  • Build a quick one-page demo and download it as a single HTML file.

Frequently asked questions

Is this a CodePen alternative?

For quick experiments, yes. It offers HTML, CSS and JS tabs, a live preview and a console. It does not have accounts, saving to the cloud or a public gallery.

Can I use npm packages or import libraries?

You can add a <script src> or <link> tag pointing at a CDN such as jsDelivr or unpkg in the HTML tab. There is no npm install or bundler.

Where does the JavaScript run?

In a sandboxed iframe in your browser, after the HTML has loaded. It cannot access this website's cookies, storage or pages.

Is my work saved if I close the tab?

No. Download the page with the Download button to keep it. Nothing is stored on a server.

Does it support Sass, TypeScript or JSX?

No. The editor runs plain HTML, CSS and JavaScript exactly as a browser would, without preprocessors.

Related tools