Convert multiple images between formats in one batch operation
By default, JavaScript running in a web browser is single-threaded. It can only do one thing at a time.
If an application tries to decode, resize, and re-encode 100 images on that single main thread, the entire browser tab will freeze. You wouldn't be able to click a button, scroll the page, or even see a progress bar update until all 100 images finished processing.
To solve this, this tool utilizes the browser's Web Worker API. Think of Workers as invisible background tabs.
Our internal WorkerOrchestrator queries your device to see how many CPU cores it has (using navigator.hardwareConcurrency). If your machine has 8 cores, the orchestrator spawns 8 separate Web Workers.
When you drop 100 images into the batch, the orchestrator distributes them across your available CPU cores. It processes 8 images simultaneously in the background.
Because the heavy computational math is happening on background threads, the main UI thread is left completely free. This guarantees that your browser remains perfectly responsive, and the progress bar animates at a smooth 60 frames per second, even under heavy load.
Traditional batch converters require you to upload hundreds of megabytes of photos to a cloud server, wait in a queue, and download a ZIP file. By using Web Workers, we bring the server infrastructure directly to your CPU. Processing is faster, bandwidth usage is zero, and your private files never leave your machine.
What happens if you try to process 100 heavy images on JavaScript's main thread?