PNG optimization is not only about compression. Sending a 2400-pixel asset into a 400-pixel slot can waste more bytes than a small encoder tweak saves. The useful question is not just what the format can do, but what changes in a real editing or delivery pipeline.
Start with the rendered slot
Before tuning compression, ask how wide the image actually appears at different viewport sizes. A source dramatically larger than every realistic display slot can waste transfer bytes and decode memory.
What srcset contributes
With width descriptors, srcset can offer several candidate resources. The browser combines those candidates with layout information to choose an appropriate file rather than always downloading the largest one.
Why sizes matters
MDN describes sizes as the layout width of the image under specified media conditions. When srcset uses width descriptors, that information helps the browser decide which candidate is suitable before full layout is complete.
Intrinsic width and height solve a different problem
Supplying width and height attributes can establish the image's aspect ratio and reserve layout space. That helps prevent layout movement; it does not force the browser to render the image at those exact CSS dimensions.
Do not generate twenty variants without evidence
Every derivative has storage, cache, build, and invalidation cost. Choose a small set that matches real breakpoints and device-density needs, then inspect which resources browsers actually request.
Compression and responsive delivery multiply
A well-compressed 2000-pixel PNG is still oversized when a 500-pixel resource would look identical in context. The strongest pipeline combines appropriate dimensions, sensible format choice, and lossless optimization where PNG remains the right format.
Sources and technical basis
Primary technical reference: W3C Portable Network Graphics (PNG) Specification, Third Edition (2025). Web-delivery sections also use MDN guidance for responsive images where relevant.