why png size doesn't change after using http gzip compression

后端 未结 4 869
隐瞒了意图╮
隐瞒了意图╮ 2020-12-31 01:50

I use following .htaccess to set gzip compression:

AddOutputFilterByType DEFLATE text/html image/png image/jpeg text/css text/javascript

Pl

4条回答
  •  -上瘾入骨i
    2020-12-31 02:35

    PNG is already a compressed data format. Compressing it with GZIP is not likely to decrease the size, and can in fact make it larger.

    I'm surprised you're seeing benefits when GZIP-ing JPGs, as they are also compressed.

    See here for Google's tips on using GZIP. They recommend not applying it to images.

提交回复
热议问题