What Is Smart Auto Image Compression and When Is It Better?
Fixed quality applies one number to every image. Smart auto searches each image for a lower quality that reaches a similarity target, which helps a batch with varied visual complexity.
Why one fixed quality is not fair
A flat illustration, natural portrait, noisy night scene, and product screenshot have different encoding difficulty. At quality 75, one may be far above the needed fidelity while another shows artifacts. A fixed value is simple and repeatable, but it cannot allocate bytes according to content.
Smart auto changes the goal from “same quality number” to “same similarity threshold.” Easy images can use a lower setting; difficult images retain a higher one.
How this implementation works
- Encode the image at a candidate quality.
- Decode the output and compare it with the resized reference pixels.
- Calculate SSIM; if it reaches 0.95, try a lower quality.
- If it misses the target, raise quality.
- Use binary search to reach a suitable range in a limited number of attempts.
When Smart auto is a good fit
| Task | Recommendation | Reason |
|---|---|---|
| Dozens of varied photos | Good fit | Allocates quality per image |
| Brand hero image | Begin with manual High quality | Local details carry more weight |
| Screenshots and small UI text | Keep PNG High quality | SSIM may not fully represent type sharpness |
| Exact lossless requirement | Not a fit | JPEG/WebP/AVIF path remains lossy |
How to review the result
Choose five difficult files from the batch: a face, fine hair, a gradient, dark detail, and small type. The auto-selected number is only a clue; the real test is the result at final dimensions and on the final platform.
- Inspect local details at 100% zoom.
- Inspect overall appearance at the final display size.
- Compare file sizes rather than only quality numbers.
- Record content types that do poorly and separate them next time.
Your files are processed in the current browser and are not uploaded as article samples.