What is the difference between .gif and .jpeg?

GIF is short for Graphics Interchange Format. GIF's advantages is that it is supported by practically all web browsers, can include transparent backgrounds, supports interlacing (providing a low-resolution preview of the graphic to the viewer while it downloads), and can be used as an image map (allowing the viewer to click on the graphic as they would a regular link to another site.) GIF's disadvantages are that it can only support 8-bit color (or a palette no greater than 256 colors). It may also handle dithering poorly, which is the result of pixels in a graphic that try to mix themselves up to emulate different colors. Photographs saved as GIFs can also lose their detail and a wide range of values. JPEG is short for Joint Photographers Experts Group. JPEG is superior in rendering color and detail found in photographs or graphics using blends, gradients, and other tonal variations. It also provides for greater compression options (Low, Medium, High, and Maximum) allowing the the artist the perfect balance between quality and file size. The disadvantages of JPEG files are that they cannot be saved in index-color mode, meaning that many people who view the images with 8-color monitors may experience unusual dithering patterns. JPEG files also do not allow for transparent backgrounds, so you are stuck with either leaving the background of the image the same color as the background of your page, or having to settle for a border around your image. Metallic images (gold, silver, copper, steel, bronze) are created using different types of gradients. Some of the gradients can be quite complex. For this reason, most metallic images should be exported or saved as JPEGs rather than GIFs. A JPEG is much better at displaying a wide range of tones, which is what a gradient is. Use a GIF format if your graphic consists primarily of line art or flat colors without gradients. JPEG-converted graphics are best for photographs or images with fine tonal variations in colors, such as images with gradients or metallic images. Choosing the right file format is not only important for the quality, but for keeping your image's file size to a minimum.