How JPEG compression actually decides what to throw away
2026-03-12
JPEG is lossy because photographs contain detail people barely see. Here is the part that matters when you pick a quality number.
A JPEG is not a grid of pixels waiting on disk. The encoder converts the image into frequency information, quantizes the parts it considers less visible, and then packs what remains with Huffman coding. The quality slider mostly changes that quantization step. It does not mean “percent of the original pixels.”
Why 80 often looks like the photo
Around the high 70s and low 80s, a photographic JPEG usually keeps edges and skin tones well enough for the web, while the file drops sharply from a camera original. Push toward 90 or 95 when the photo will be cropped again or printed. Quality 100 still discards information with a standard JPEG encoder; it is not a lossless mode.
Chroma subsampling
Eyes notice brightness more than fine color. At moderate quality, PixelShrink uses 4:2:0 chroma subsampling through mozjpeg, which stores less color detail. At quality 90 and above it keeps 4:4:4 so red type and product colors stay cleaner. Screenshots with solid color blocks still survive this poorly. Those belong in PNG or WebP.
What a second save does
Opening a JPEG and saving it again quantizes an already quantized image. Generation loss shows up first as halos around text and as blotches in skies. If you still have the camera original, compress from that. If you only have the JPEG, prefer one careful re-encode over several “small tweaks.”
- Use JPEG for photographs.
- Keep PNG or WebP for interface shots, diagrams, and transparency.
- Strip metadata separately from quality. A tiny file can still contain a GPS coordinate until you remove EXIF.
Related
- JPEG compressor — Apply a quality number to a real file
- Image resizer — Shrink the grid before another encode
- EXIF guide — Metadata is separate from quality