Code Formatter
Paste messy code and get it beautifully formatted using Prettier-compatible rules. Supports JS, TS, JSX, TSX, HTML, CSS, SCSS, JSON, YAML, and Markdown.
Indent:
Click Format →
Frequently Asked Questions
Which formatter is used?
JavaScript, TypeScript, and Markdown use Prettier (the industry standard). JSON uses the browser's built-in JSON.stringify. HTML and CSS use lightweight rule-based formatters. All processing is client-side — your code never leaves your browser.
Why is formatting slow the first time?
Prettier's standalone browser build is loaded on demand (~300KB). After the first format, it's cached and subsequent formatting is instant.