Squoosh is Google's browser-based image compressor. Convert images to WebP, compare formats side by side, and know when to use it vs cwebp.
Squoosh WebP Conversion: Browser-Based Optimisation
Squoosh is a free browser-based image compressor from Google Chrome Labs. It converts images to WebP entirely on your device, using WebAssembly codecs, with a side-by-side preview that shows the quality and size trade-off in real time. This guide covers converting to WebP with Squoosh and when to choose it over a command-line tool or a batch pipeline.
For the format itself, see What is WebP?. For a single-purpose browser converter, use PNG to WebP and JPG to WebP.
What is Squoosh?
Squoosh is an open-source image-optimisation web app built by Google Chrome Labs, available at squoosh.app. It compresses images locally in the browser using WebAssembly ports of codecs including WebP, AVIF, MozJPEG, and OxiPNG. No image is uploaded to a server.
Squoosh is a single-image tool focused on visual comparison. It is ideal for tuning one image and seeing the result before committing to a setting across many.
How do you convert an image to WebP in Squoosh?
Open squoosh.app, drop in an image, and choose WebP as the output format in the right-hand panel. Squoosh shows the original and compressed versions side by side with a draggable divider, then lets you download the WebP. The quality slider updates the preview and file size instantly.
The steps are:
- Open squoosh.app and drag in an image.
- Set the right-hand format selector to WebP.
- Adjust the quality slider and watch the live size and preview.
- Download the result.
What makes Squoosh's preview useful?
Squoosh's split-screen preview shows the exact visual cost of each quality setting before you commit. The divider compares original and compressed pixels at the same zoom, and a live byte counter shows the saving. This makes it the best tool for finding the lowest quality that still looks acceptable.
Use Squoosh to discover the right quality value for a content type, then apply that value at scale with cwebp or a batch pipeline.
Does Squoosh have a command-line version?
Squoosh's command-line tool (@squoosh/cli) is no longer maintained — Google archived it in 2022. For automated or batch WebP conversion, use cwebp, the Node libraries sharp or imagemin, or another maintained pipeline instead.
The maintained command-line path for WebP is cwebp; the maintained programmatic path is the libwebp library or sharp. Batch options are compared in Batch Converting Images to WebP: CLI and Automated Workflows.
When should you use Squoosh versus other tools?
Use Squoosh for tuning a single image visually; use cwebp or a batch tool for many images. Squoosh excels at the exploratory step — finding the setting. It is impractical for converting a whole directory because each image is handled one at a time in the browser.
Choose by task:
- Tuning one image and comparing formats — Squoosh.
- A few quick conversions — PNG to WebP, JPG to WebP.
- Whole directories or build pipelines — cwebp or batch tools.
Where to go from here
- cwebp Command-Line Tool: Full Reference Guide
- Batch Converting Images to WebP: CLI and Automated Workflows
- Lossy vs Lossless Compression: When to Use Each for WebP
- What is WebP? A Complete Guide to the WebP Image Format
- Single-purpose converters: PNG to WebP, JPG to WebP
Squoosh is the best tool for finding the right WebP setting one image at a time. Once you know the value, apply it at scale with cwebp or a batch pipeline.