PNG quality: why the file size does not change
Apps24 disables the quality slider for PNG because this setting cannot reduce its file size. Its browser canvas encoder applies quality to JPEG and WebP, not PNG. To check this rather than assume it, we encoded the same synthetic gradient at two PNG qualities and compared bytes and SHA-256 hashes.
Input and result
PNG 20% | 3,304 bytes |
PNG 80% | 3,304 bytes |
WebP 80% | 2,074 bytes |
JPEG 80% | 3,916 bytes |
PNG SHA-256 | 54e456a5602aae16b8bd75c1fc688858e1b447fe251ce9280e9431bce261e53e |
What the result means
Both PNG files were 3,304 bytes with the same hash. WebP at 80% was 2,074 bytes, while JPEG was 3,916 bytes: changing formats did not always help. The gradient is a controlled sample, not a photograph or a benchmark of all images. Matching hashes show that these two PNG outputs are identical; file size alone would not prove that.
What to do next
For PNG, reduce dimensions if fewer pixels are acceptable. Otherwise try WebP and inspect edges, small text and transparency. JPEG is an option for opaque photos but Apps24 replaces transparency with white. Compare original and output bytes before downloading. If savings are negative, keep the original unless you need the new format.
Use the toolLimits and test conditions
Test: Chromium 154, 320×200 opaque pixels; R=x mod 256, G=y mod 256, B=(x+y) mod 256, alpha=255. No resizing. Results depend on content and browser encoders. The downloadable script reproduces this sample. Lossy file size is not a perceptual quality score.
png-fixture.jsReferences
Apps24 checks examples against the implementation and regression tests. Browser experiments state their conditions; they do not certify every device. Report an error with the page URL, input, expected result and browser. Never send passwords, private documents or personal data.