Graphic File Formats



There are many graphic file formats.  However, the ones usually used in web pages are:

1. GIF Format
2. JPG Format
3.  PNG Format

GIF Format is generally used for clip art and graphics with fewer than 256 colors.  GIF files support transparency.

JPG or JPEG format is used for photographs. Transparency is not supported.

PNG (pronounced "ping") is a newer file format that supports some transparency.  Better used for clipart than photographs.

When in doubt, choose JPG!

Here is our picture, in all three formats, notice the file sizes:

JGP

The file size is 13.9 K

GIF

The file size is 18.4 K.

PNG

The file size is 86.5 K, after being optimized!  Prior to optimization, the file size was 224 K.

Which picture to use is an easy choice.  The JPG has the smallest file, with the great quality.  You can  easily see why GIF is a bad choice for photographs.  The PNG produces a nice quality picture, but also has a large file size.