There are two kinds of image formats : lossless and lossy. The lossless image formats allways contain all of the original image data. The lossy image formats lose some of the original image data by using compression techniques. The main advantage for using lossy techniques it that it enables savings in disk storage space. If the image details are vital, like in medical X-ray images, lossless formats have to be used. The most used lossy image format is JPEG, which is now also included in TIFF. The lossy techniques usually act like image low-pass filters: By filtering out the higher vertical and horizontal frequencies (= little details) from a picture, it can be saved in a much more compact way. Here are example of lossless and lossy images.
Lossless GIF image
Lossy JPEG
more lossy JPEG
very lossy JPEG