Free, no signup, runs in your browser
Free online JavaScript minifier
Paste your JavaScript and press Minify: extra spaces and line breaks go, names inside functions get shorter, and you see the size before and after with the percent saved. Your browser does it all, so your code is never sent to a server.
Everything runs in your browser. What you paste isn't sent anywhere.
Want a link to the page this script runs on?
Upload the page's HTML file or paste its code, and Convika gives it a link that opens in any browser. Free, no signup.
How to minify JavaScript online
- Paste your JavaScript into the box, or open a .js file from your device.
- Press Minify.
- Press Copy, or Download to save it as script.min.js.
What does minifying JavaScript do?
It removes comments, line breaks, and extra spaces, shortens names, and writes expressions in shorter forms. The file gets smaller, so the page loads faster.
Can other scripts still call my functions?
Yes. Functions and variables at the top level of a script, and what a module exports, keep their names. Only names that other scripts can't reach get shorter.
Are license comments kept?
Yes. A block comment that starts with /*! or has @license or @preserve in it stays, so a library's notice travels with the file.
Guides
How to share an HTML file as a link that opens on any phone
Upload the file to a host and send its link; email and Google Drive send the code. 8 hosts compared, from Convika to Netlify Drop, with 4 steps.
How to open an HTML file on iPhone
Open an HTML file on iPhone in 3 steps: save it to Files, open a free HTML viewer in Safari, tap Choose an .html file. It runs with CSS and JavaScript.
How do I open an HTML file on iPad and make it run?
Open an HTML file on iPad in 3 steps: save it to Files, open a free HTML viewer in Safari, tap Choose an .html file. Its CSS and JavaScript run, no app.
How do I open an HTML file on Android in Chrome mobile?
HTML file shows code or won't open on Android? Open it in Chrome with a free HTML viewer and the page runs, buttons and all. No app, no account.
How do I create a QR code for an HTML file?
To convert an HTML file to a QR code, publish it at an address that stays, then click Show QR code and download a PNG. The code holds a link, not the file.
How do I share an HTML file on Google Drive, or send it as a web page?
Share an HTML file on Google Drive: upload it, set it to Anyone with the link, and copy the link. People get the file, not a web page; Convika's free upload box turns it into one.
Submit an HTML file in Google Classroom so your teacher sees the page
Classroom takes an HTML file, but the teacher gets the file. Hand in a link to the page instead. Teachers post a game for their class the same way.
How do I send an HTML file on WhatsApp so it opens in one tap?
Send an HTML file on WhatsApp with Document and it arrives as a file. To share it so it opens as a page in their phone's browser, send a link instead.
How to send an HTML page on LINE so it opens in one tap
LINE's help doesn't say how a phone opens a received .html file, and LINE keeps files for a limited time. Send a link instead; it opens in a browser.
How to open an HTML file in Safari on iPhone or iPad, and on a Mac
To open an HTML file in Safari on iPhone or iPad, open the free HTML viewer and tap Choose an .html file. On a Mac, open a local HTML file with File > Open File (Command-O).
file://error_page_loaded.html, code, or a blank page: how to open your HTML file
file://error_page_loaded.html is what Chrome on an iPhone or iPad shows when a page didn't load. Open your HTML file in a free viewer in a few taps.
How to open an HTML file on any computer, phone, or tablet
Double-click an .html file to open it in your browser. On a phone, open it in Convika's free HTML viewer. What an HTML file is, steps by device, and fixes.