Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I try to convert a JPG file to PNG, but the size is still too big, about 7 MB. What's wrong? I used Microsoft Paint to convert it.

The original file is only 500 KB in JPEG, yet the PNG file is 7 MB.

What's wrong? And what should I do?

This is the jpeg file http://www71.zippyshare.com/v/96674516/file.html

share|improve this question

2 Answers 2

up vote 3 down vote accepted

slhck's answer is almost correct, but the main difference between those two formats lies in the size of the palette (number of colors) used. If the palette is relatively small converting a jpeg into png will in fact reduce its size. Another problem you have is using paint for pngs: it is well known that paint doesn't optimize its pngs. Try something like pngoptimizer to reduce the size of the pngs generated by paint.

share|improve this answer
    
I tried photoshop and got 3MB instead of 7MB. This is a much better answer. –  Jim Thio Apr 2 '13 at 11:07
    
note that you can still optimize photoshop's pngs. but for a photography png will never catch up to jpeg –  bobrobbob Apr 2 '13 at 11:11
2  
@JimThio If you explained more about the problem you were trying to solve I could have provided you with a more specific answer. We couldn't magically guess that reducing the bit depth or number of colors was an option for you, because that entirely depends on the situation and material used (e.g. images versus plain graphics). Please try and be more specific next time. –  slhck Apr 2 '13 at 11:12
    

Nothing's wrong: This is how it is supposed to be.

PNG images use lossless compression, whereas JPEG uses lossy compression. Lossy compression lets you reduce the file size, but it is not reversible.

When you convert from a lossy JPEG picture, which stores the data in blocks, to a PNG image, which stores pixel-by-pixel values in a bitmap, you will increase the size needed to represent the data.*

So, converting a PNG into JPEG will (usually) reduce the size, but this is not possible the other way round.

* Unless the data was easy to compress with a lossless algorithm, for example because it was an image with a flat, solid color.

share|improve this answer
    
Not "always increase", since PNG was designed to use a data compression algorithm on those "pixel-by-pixel values", so if the image has many large areas of the same colour (and the JPEG lossyness didn't get in the way) it is quite possible to have "the other way round". –  C.B. Aug 20 '13 at 10:57
1  
You're right, I amended my answer. –  slhck Aug 20 '13 at 11:01

Your Answer

 
discard

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.