FREE TOOL · ON YOUR DEVICE
Minify CSS, JavaScript and HTML for free
Make your code lighter before publishing, or make a compressed file readable again. Paste or open CSS, JavaScript, HTML or JSON, choose minify or format, and copy or download the result. The code is never sent to a server: it is processed on your device.
- Free with an account
- CSS, JS, HTML and JSON
- Minify or format
- Paste or open your code
- Choose what to do
- Copy or download
HOW TO USE IT
Three steps.
Paste or open your code
Up to 2 million characters. The language is detected when you paste; you can change it under “Language”.
Choose what to do
Minify removes spaces, line breaks and comments. Format indents CSS, HTML or JSON so you can read it. You can keep licence comments /*! … */.
Copy or download
You see the size before and after in bytes. Press “Copy result” or “Download”.
NEXT STEP
Keep going with these tools
Minify code: common questions
Does it change what my code does?
It should not: it only removes spaces, line breaks and comments that do not change the result, and it never renames variables. For JavaScript the result is read again and, if it does not have the same pieces in the same order, it is not delivered. Still, test your site before publishing.
Can I format JavaScript or use JSX and TypeScript?
Formatting is available for CSS, HTML and JSON; JavaScript can only be minified. JSX and TypeScript are not supported: convert them to JavaScript first.
How much smaller does it get?
It depends on the code: you see the bytes before and after and the percentage saved. Since it does not shorten variable names, it saves less than a compiler that does, but it does not change behaviour.
Is my text sent to a server?
No. Everything is calculated in your browser as you type; the text is not sent to Cocuyo or any third party and is not stored. You can check it in your browser’s network tools: your file is not sent.
Is it really free?
Yes. You can try it before signing up; to keep using it, we ask for a free account, with no subscription. It uses no credits and does not count toward your 30 welcome uses: it has no usage cap.
MORE FREE TOOLS
Other text tools
All free tools
WHEN YOU WANT TO CREATE
Make new images with AI.
Cocuyo’s Studio brings 30+ AI models for image, video and voice together. You see the credit cost before generating, and credits never expire.