Lightroom 3 Book for Digital Photographers by Scott Kelby »

Which Image Format: JPG, GIF, or PNG

There are three primary image formats used on the web: (1) JPG, (2) GIF, and (3) PNG -- pronounced "j-peg", "gif", and "ping" respectively.

JPG

JPG stands for Joint Photographic Experts Group. JPG format is ideal for photographs because it can render 16 million different color tones. It is good when the image has many different shades and gradients. JPG does not support background transparency.

JPG uses lossy compression which means that it compresses file size partly by throwing out some colors from the image that it thinks the human eye will not notice.

More about JPG format »

GIF

GIF stands for Graphics Interchange Format. The benefit of GIF is that it supports background transparency and animation. Animated images are known as "animated gifs". The downside is that it can only render 256 different colors. So if you have images that are mostly flat solid colors such as cartoons, then GIF is good. If you save a web graphic with gradient colors as GIF and you see "striations" (or bands of colors), that means that GIF is not able to render the "in between color tones" and you should try JPG or PNG format.

GIF uses lossless compression.

More about GIF format »

PNG

PNG stands for Portable Network Graphics. In that past JPG and GIF where the primary two choices to choose from. Today, there is a third. There PNG format is a hybrid between the JPG and GIF. It can support a much larger color depth than GIF and support alpha transparencies. Alpha transparency means that a pixel can be partially transparent which means that you can set colors at different opacity. Keep in mind that the Internet Explorer 6.0 browsers does not know how to render transparent PNGs -- non-transparent PNGs are fine. PNG uses lossless data compression. PNG comes in different bits

More about PNG format »

Comparisons between JPG, GIF, and PNG

To learn more about the differences between the three formats ...

  • JPG vs. GIF vs. PNG on Webopedia
  • GIF, JPG and PNG - What's the difference? - on Sitepoint