Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is there any use in setting the PNG and JPEG compression in GeoServer (Services - WMS - PNG Options/JPEG Options)?

The default is 25, but we heard rumours that having compression resulted in a time penalty for decompression on the way out, so we set it to 0. We deliver PNG8 and JPEG tiles, and these are relatively small but if we can make them smaller without significant quality or time loss then that would be great.

We just aren't sure whether sticking compression on would reduce the image sizes but result in a (significant) time penalty or not and would like to know for certain.

FYI We can't really just test it as currently we do not have a Dev GeoServer environment!


share|improve this question
I don't think you'll get a definitive answer - it will depend on your exact data sets, server and bandwith so a series of small tests is the way to go. – iant Jun 18 '12 at 12:49
Optimal traffic / display time comes from a healthy balance of both image quality and image compression. I agree with iant, you will need to fine tune the values for your own environment. Also consider what is more valuable to you, server resources or end-user experience. – nagytech Jun 18 '12 at 13:41
up vote 3 down vote accepted

Increasing compression above 25 often results in a severe performance degradation of the PNG encoder, thought with png8 I've observed less of it. Doing the same with JPEG results in a degradation in image quality, did not measure performance but it seemed similar by the naked eye.

share|improve this answer
Exactly what we thought to be honest, it's just a pain in the ass not having a Dev environment to test this stuff in! Cheers! – Rob Quincey Jun 19 '12 at 8:15

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.