WEBPery

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:

  1. Open squoosh.app and drag in an image.
  2. Set the right-hand format selector to WebP.
  3. Adjust the quality slider and watch the live size and preview.
  4. 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:

Where to go from here

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.

What is WebP? A Complete Guide to the WebP Image Format

WebP is Google's image format with lossy and lossless compression. Learn how it works, browser support, file sizes, transparency, and animation.

WebP Transparency: Alpha Channel Support

WebP supports an 8-bit alpha channel in lossy and lossless modes. How transparency is stored, the ALPH chunk, file-size cost, and PNG comparison.

srcset and WebP: Responsive Images with Format Fallback

Use srcset and sizes to serve responsive WebP at the right resolution per device, with a JPEG fallback. Width and density descriptors explained.

WebP File Structure: RIFF Container and Chunk Format

How a WebP file is structured: the RIFF container, the WEBP FourCC, and VP8, VP8L, VP8X, ALPH, ANIM and ANMF chunks. The byte layout explained clearly.