Image Histograms

Images are made up of pixels. Pixels are tiny elements of the image whose color is defined by values for three color channels: Red, Green and Blue (RGB). When a sensor records light it records tonal values as a number from 0 to 255. A histogram is a graphical representation of the tonal distribution of all the pixels in a digital photograph. Histograms can be viewed for the gamma (light and dark) values of an image and also for each of the three color channels.

Along the bottom of the histogram chart is a gradient which indicates the intensity value for that color of pixel. The left side of the gradient is black and the right is white. The vertical axis indicates the number of pixels that are found at each value. An ideal image histogram will have an even distribution of pixels spread between 0 and 255. The peak should be towards the middle of the graph.

How do I view it?

You can view the histogram of a digital photograph in a number of different ways.

The first and most important way to view a histogram is on your digital camera itself. Many cameras have a built in histogram display as part of the playback or preview mode. Since every manufacturer sets up the control systems for the camera differently you will have to research in the manual or online to find out how to turn on the histogram for your camera. Understanding histograms and viewing them on your camera while shooting can help you determine if your picture is exposed correctly.

Histogram on Screen
Histogram on a Digital Camera

Being able to quickly analyze an images histogram can tell you if the photo was properly exposed and if not it can give you a very good idea of how to fix the exposure. Images which are obviously over exposed will have a histogram that peaks toward the right side of the graph and may even have some color values that are pushed all the way to the right side - this indicates blown out or overexposed pixels. If a histogram is far to the right you may want to try another exposure with a lower ISO, slower shutter or adjust your EV settings. If the image is underexposed the opposite will be true - the histogram will be shifted left.

You can also view the histogram information for a digital photo even after you have gotten it off of the computer. Programs such as GIMP or Photoshop will let you view and adjust the histogram to manually fix exposure problems.

GIMP Levels with Notes
Histogram levels in GIMP

If you shoot in RAW you may need a special program to view the unprocessed images. If you don't have a piece of software from your camera manufacturer you may want to experiment with a GIMP plugin called UFRaw. UFRaw lets you view advanced histograms for the different channels and adjust them directly from the raw image capture.

UFRAW
My delicious breakfast in UFRAW

What does it all mean?

The best way to start interpreting and evaluating histograms for digital photos is to simply start looking at them. Here are four example photos with their histograms and a brief interpretation of the chart.

Mansfield Sky
This is a good exposure with a nice histogram. The chart is spread over a wide range indicating that the image has an even tone to it. The fact that there are two major peaks could be an indicator of a bad exposure but in this case we can see that there are two distinct parts of the photo. There is the dark mountain - creating the left peak - and there is the brighter sky - the right peak. Even though there is a good amount of bright color in the sky none of the pixels are blown out and so overexposure has been avoided.

Dark Tractor

This photo has a similar histogram as the previous image. Again the two peaks are caused by the two tonal areas - light sky and dark tractor and trees. This time however the picture is not as well exposed. The graph is shifted far to the left meaning that more of the pixels are in the dark region. This is a byproduct of underexposure. When treating digital photos underexposure can be easier to compensate than over exposure. This picture could be lightened to bring forward more detail. An underexposed pixel can be brightened while retaining its color value. An over exposed pixel can not be recovered and will always show up as pure white. Images which are dark and have a histogram that is farther to the left are called "low key" images.

Truck
This exposure of some cars has a nice curve to its histogram. While it is shifted to the left due to a slight underexposure the chart itself is a smooth single curve. This indicates an even distribution of tones and a correct exposure. This image could easily be brightened to bring out more vivid colors and tones. What makes the quality of this photo so good is the high contrast. This high contrast is indicated on the histogram by the tight curve shape. Where the dark picture of the tractor has a similar histogram in some respects it is has a much more spread out range of tones and has less contrast.

Window
Here is an example of an over exposed photograph. The histogram is pushed against the right side of the graph. This means there are many overexposed or blown out pixels. These pixels can not be adjusted because they only have white value and the highlights of the picture will remain over exposed regardless of future adjustments made to the color levels. Unlike low key images, bright images like this that have a histogram pressed to the right are known as "high key" images.

Here is a video of these values being adjusted in GIMP. Learn how to manipulate histograms and color channels here.

Further Reading
Using the Photoshop Levels Tool
Understanding Histograms

Back to Index