Guide

How photo compression works: JPEG, WebP and the quality slider

A photo file is made small by throwing away detail your eye is unlikely to miss. JPEG cuts the picture into small squares, keeps less color than brightness, and rounds away fine detail in each square; the quality setting decides how much is rounded away. That loss is permanent, and each new save of a JPEG loses a little more. PNG keeps every pixel and is much larger for a photo. WebP can do either, usually in a smaller file.

Last checked

On this page

Lossy and lossless

There are two ways to make a picture file smaller.

  • Lossless formats such as PNG store the picture in a cleverer way, like a zip file. Every pixel comes back exactly. For a photo the file stays large, because a photo has few exact repeats to pack away.
  • Lossy formats such as JPEG throw away detail that the eye is unlikely to notice. The file gets much smaller, and the detail does not come back. The Wikipedia article on JPEG says JPEG typically shrinks a picture about 10:1, with a loss you can see if you look for it but that is widely accepted.

MDN’s guide to image formats lists JPEG as lossy and PNG as lossless, and says JPEG suits photographs and does poorly on diagrams and charts.

What a JPEG does to a photo

The steps below are a simplified version of what the JPEG article describes.

  1. Brightness and color are split. Your eye sees fine changes in brightness much better than fine changes in color, so color is often kept at a lower resolution. Most commonly it is halved both across and down, which leaves a quarter of the color detail.
  2. The picture is cut into squares of 8 by 8 pixels.
  3. Each square is turned into patterns. Instead of a value for every pixel, the square is described as a smooth base tone plus finer and finer ripples on top.
  4. The fine ripples are rounded off. This is where detail is lost for good. The quality setting decides how hard the rounding is: low quality rounds away most of the fine ripples, high quality keeps more.
  5. What is left is packed tightly, without further loss.

When the rounding is heavy, the squares start to show: blocky skies, smudged edges around text, halos around leaves against the sky.

Why saving again makes it worse

Open a JPEG, change nothing, and save it as a JPEG again: the rounding runs a second time on a picture that was already rounded, and a little more is lost. The JPEG article calls this a loss on each recompression. A photo that has been edited, saved, sent and saved many times shows it.

Keep one original, and make every small copy from that original, not from another copy.

WebP, PNG and HEIC

  • WebP has a lossy mode and a lossless mode, and keeps transparency. MDN puts lossy WebP at 25 to 35% smaller than JPEG on average at a similar look. Some older programs cannot open it.
  • PNG keeps every pixel and transparency. Right for screenshots, drawings and logos; heavy for photos.
  • HEIC is the format an iPhone camera uses with its High Efficiency setting. Apple says it compresses better than JPEG, which is why turning a HEIC photo into a JPEG can make the file bigger, not smaller.

What the quality slider really sets

In a browser, the quality setting is a number from 0 to 1 that the browser passes to its encoder, and each browser’s encoder interprets it in its own way. So the same number gives slightly different files in different browsers and apps. The image compressor on this site shows the size and a full-size patch of the photo before and after, so you can judge the result by eye rather than by the number.

Where Sealed helps, and where it doesn’t

It helps keep the full original sealed while the small copies go out, so there is always a first-generation file to make the next copy from. Photos and videos are sealed the moment they arrive, and afterwards you can remove the originals from Photos if you like. Viewing and exporting your own photos is always free.

It doesn’t compress photos for you, and nothing can bring back detail that a compressed copy has lost. The guide to compressing a photo for email puts the ideas here into steps.

Questions and answers

Does a lower quality setting make the photo smaller in pixels?

No. The width and height stay the same; only the detail inside the picture is rounded away. To change the width and height, resize the photo. Doing both saves the most.

Is quality 100 the same as the original?

No. Even at the top setting a JPEG still rounds and still keeps less color than brightness, so a little is lost, and the file is often larger than the original.

Why do screenshots look bad as JPEGs?

Screenshots are full of sharp edges and flat color, which is exactly what JPEG handles worst: you see smudges around text. Save screenshots, drawings and logos as PNG.

Sources

What this page says about Sealed was checked against the app on .

  • Wikipedia, JPEG — the picture is split into 8 by 8 pixel blocks, color is kept at a lower resolution, rounding (quantization) is where detail is lost, about 10:1 usually looks the same as the original, heavy compression shows block edges, and each recompression loses more; read 13 Nov 2026
  • MDN Web Docs, Image file type and format guide — JPEG is lossy and has no alpha channel, PNG is lossless with full transparency, WebP has lossy and lossless modes, lossy WebP is on average 25 to 35% smaller than JPEG and lossless WebP about 26% smaller than PNG; read 13 Nov 2026
  • MDN Web Docs, HTMLCanvasElement: toBlob() method — a browser’s quality setting is a number from 0 to 1 for lossy formats; read 13 Nov 2026
  • Apple Support, Using HEIF or HEVC media on Apple devices — HEIF and HEVC compress better than JPEG and H.264 and use less storage; the camera’s High Efficiency setting uses them, Most Compatible uses JPEG; read 13 Nov 2026
  • Sealed on the App Store — the listing for the app this page ends with

Last checked:

Get Sealed

Sealed is free to download, and Sealed Pro is an optional in-app purchase.