Tap to Read ➤

Different Image File Formats Explained

Anand Karwa
Have you been encoding all your digital images to .jpg? Although .jpg is good, it is not the most ideal graphic file format for every situation. Let us learn about the different image file format extensions that are popularly used so that you can give your to-be-encoded images a new life.

Point to Ponder

We all agree that images speak more than words, but have you ever thought why do we have so many digital image formats? What are their uses, and the most ideal usage scenarios for obtaining best results?
Digital images have become synonymous with social networking websites and the Internet.
Without images, the Internet would be a dull, boring and ugly place.
If you download images from the Internet frequently, then you might have noticed that different images have different file extensions. There are other image file formats like WEBP, TIFF, etc. The reason for having such a large variety of image file formats is because each has its own pros and cons. Not every image file can be used in every situation.

Your browser doesn't support HTML5 video.

It might come as a surprise to smartphone selfie-conscious users that .jpg is not the best format for storing very high quality photos. Yes, there are many other types of image file format extensions that can store photos with zero loss in quality. Broadly speaking, there are 2 main categories of image file formats. Let us take a closer look at each of them.

Raster Images

These images are composed of an array of pixels, with each pixel having its own color information in the form of bits/pixel. A pixel is made up of 3 sub-pixels―R, G, B.
Each of these sub-pixels usually have up to 8 bit (2^8 values) of memory for representing an individual pixel. As these raster images are made up of pixels (blocks), they tend to pixelate (blocky) when enlarged more than their original resolution.
The most popular types of raster images are:

JPEG (Joint Photographic Expert Group)

JPEG is one of the most popular image file formats.
It supports both types of image compressions―lossy and lossless. These are true-color images (24 bit/pixel), and thus, give a natural look to the photographs. While encoding in JPEG, a lot of data is discarded to keep the size of the resultant image small. It doesn't support animation and transparency.

GIF (Graphics Interchange Format)

The GIF file format is suitable for compressing images with 256 colors or less.

Your browser doesn't support HTML5 video.

As you know, a GIF can be animated to show animation and provide effects. These images are immensely popular on online forums. This file format is also ideal for storing logos, drawings, and text, but not photos.

PNG (Portable Network Graphics)

It was made as a free-to-use image file format for superseding GIF.
In the 1990s, you had to acquire a license to encode in GIF. It is also a lossless file format and supports better transparency than GIF files. It also supports true-color images but results in large file sizes. It doesn't support animation, but is good for working with images.

TIFF (Tagged Image File Format)

TIFF is not a popular file format among regular users, but it is a recognized image format in the media and publishing industry.

Your browser doesn't support HTML5 video.

It can support lossy as well as lossless compression. These images are much larger in size than JPEG and are also compatible with many browsers. This limits its reach only to commercial environment and studios.

BMP (Bitmap)

It is also known as bitmap image and was developed by Microsoft. All Windows OS handle BMP image files very well. In fact, any program made for Windows can handle this file.
The downsides to using BMP format for encoding images are its extremely large file size, its inability to scale down and scale up without much distortion, and incompatibility with other devices. On the other hand, BMP images have a very simple file structure and are lossless.

WebP

It a web-optimized open image file format supporting both lossy and lossless compressions. It was released by Google in 2010 for improving web page load speed. According to Google, conversions from PNG to WebP, and from animated GIF to lossy WebP, can shave off 45% and 64% of image size, respectively. It also supports animated and transparent images.

Vector Images

Unlike raster images, vector images are not composed of pixels. They are made up of lines. 
Vector images contain data about where the lines start and end, location of curves, color information, and borders. Vector images are highly scalable, and they don't produce artifacts of any kind. These images are very popular among artists and the commercial printing industry.

SVG (Scalable Vector Graphics)

It is one of the most popular vector image file format. It was developed by World Wide Web Consortium (W3C) as a versatile and scriptable image format for the Internet. It doesn't support any compression, but as it is based on xml, it can be compressed using gzip compression.
These are some of the hugely popular image file formats. Now that you know the advantages and disadvantages of each image file format, remember to choose the right file format when you encode your next image. Good luck!