JavaScript formatter
Paste JavaScript and get it formatted like a modern code style guide.
Free, no sign-up, no uploadHow it works
Paste your JavaScript code in the box, choose the indent (2 spaces, 4 spaces or tab) and press Format.
Copy the result or download it as a file. Nothing is sent to a server: the formatting runs in your browser.
Private by design
Everything happens on your device. Files are not uploaded to any server.
Frequently asked questions
Is my JavaScript code uploaded anywhere?
No. It is formatted inside your browser and never leaves your device, so it is safe for private code.
Which indent can I choose?
2 spaces, 4 spaces or a tab.
Does it work with TypeScript?
Yes, pick TypeScript from the language list.
Related tools
HTML formatterFormat, indent and minify HTML online in your browserCSS formatterFormat, beautify and minify CSS, SCSS and Less online in your browserJSON formatter and validatorFormat, minify and validate JSONQR code generator that never expiresQR codes for links, text and Wi-Fi, no expiryUUID generatorGenerate random UUID v4 identifiers, one or hundreds at a timeRandom name pickerPick random names from a list or shuffle them into a random order