Skip to main content

Photography 101: What is a histogram, and how do you use it?

It’s easy to set exposure by eye. We’ve all done it. The problem is that the electronic viewfinder or LCD screen on your camera does not show a 100% accurate representation of what the sensor is recording, and your own eyes may be focused on one part of the image while ignoring another. You could have blown-out highlights or crushed shadows that will only become apparent later when you open the photo in editing software on a computer.

The histogram takes the guesswork out of setting your exposure by showing you a graph of pixels arranged from dark to light. It provides hard data to confirm whether or not you have any areas of the image that are too dark or too bright for the sensor to capture correctly, or what are called “clipped” pixels.

Recommended Videos

This is not to say only photos with no pure black or pure white pixels are acceptable. It’s up to the photographer to determine whether it’s OK for certain areas of the photo to clip.

A histogram is also useful when editing your images, to let you know how far you can push or pull exposure before clipping pixels. Here’s how to use it.

More photography 101

What is a histogram?

A histogram is a basic bar graph that visually represents some set of data. In photography, it illustrates the pixels that make up your image in a two-dimensional graph. The x-axis shows brightness, from black to white, and is the main area of concern. If the graph is spilling over the left edge, you have pixels that are too dark; spilling over the right edge means there are pixels that are too bright. Ideally, all pixels should fall between the left and right extremes, although this isn’t always possible as we’ll explore later.

An example of a DSLR's histogram. (Image via Nikon)
An example of a DSLR’s histogram. (Image via Nikon) Image used with permission by copyright holder

The y-axis simply shows the number of pixels found in any given brightness region. Unlike the x-axis, there’s no “correct” position on the y-axis. The number of pixels at any given brightness level is simply dictated by your subject. If you photograph a bright blue sky, for example, you’ll see a tall spike on the right side of the histogram — you don’t have to worry about how high that spike is, only how close it is to the right edge.

How do you use a histogram?

In your camera, the histogram can be found either when reviewing images or during live-view shooting, either through the LCD screen or an electronic viewfinder in the case of mirrorless cameras. It is usually not turned on by default, so check your camera’s playback or display settings to activate it.

Despite being one of the best ways to quickly and accurately judge your exposure, the histogram is often overlooked by amateur and novice photographers. After all, if you don’t know what it is, a histogram just seems like a weird graph, and many people have no idea how to use it to their advantage. Also, the “ideal” histogram is different for every shot and changes depending on the look you desire. So when you’re not comfortable with the histogram, there can be a lot of hesitancy to rely on it.

But knowing if pixels are being clipped is important as this represents a loss of detail, and the histogram is often the only reliable way to convey this information. In an overall dark scene with small areas of highlights, a camera’s default meter reading will want to expose for the shadows at the risk of blowing out those highlights. By monitoring the histogram, you can raise the exposure just to the point of clipping the highlights without crossing it, ensuring you’re capturing the maximum amount of detail.

The problem of dynamic range

On its own, the histogram is just objective data unaware of context. For that reason, only you as the photographer can tell if a histogram is “correct.” If you want the photo to look dark, the graph should be weighted to the left. If you want it to look bright, it should be weighted to the right. A complex scene, such as a landscape with a mix of sky, ground, water, and foliage, will have little spikes all over the histogram.

But in all cases, it is generally considered “incorrect” for the graph to spill over the left or right edges. However, there are times when you simply can’t avoid this due to the limitations of your camera’s dynamic range.

In a high-contrast scene — that is, one with both very bright highlights and very dark shadows — it may be impossible for your camera to accurately reproduce every tonal range. In these cases, you will have to accept either crushed shadows or blown-out highlights — or both. If your primary subject is in the darker tones, you may have to adjust exposure so that the highlights are clipped — but at least you’ll have the detail where it matters in the shadows.

To ensure that you lose the minimum amount of detail possible, rely on the histogram to tell you when the exposure is properly set. In the above example, you should increase exposure just to the point that the graph barely touches the left edge. To instead preserve detail in the highlights, do the opposite: Decrease exposure until the graph just reaches the right edge. This way, you know you’re getting all of the detail where you need it without sacrificing more than necessary on the other end of the spectrum.

Exposing to the right

This is a fairly common term you will hear among experienced photographers, and it directly references the histogram. It means that you should always aim for a right-weighted histogram — at least, whenever possible. Digital cameras encode highlight information with much more accuracy than shadow information, so if you can shift a darker image into the highlights, you’ll have more data to work with, resulting in a higher-quality photo — even if you reduce the exposure in post back to “normal” levels.

This approach, however, can lead to problems in high-contrast scenes. If your camera lacks the dynamic range, you won’t be able to overexpose the image without blowing out highlights. So while “exposing to the right” is technically sound advice, it comes with a very large caveat: It only works for scenes with relatively low contrast.

Using a histogram when editing

While the in-camera histogram is important to initially capture the most detail, in editing it plays a slightly different role. It still indicates how far an exposure can be increased or decreased without losing detail, but it also serves as an objective balance to our very subjective eyes. Our eyes can be terrible judges, and it’s easy for them to be fooled after hours of staring at a computer screen. Something you think is just right may in fact be too bright. It’s a good idea to check the histogram every so often to make sure your exposure is still correct.

Also, given how every screen on every device is likely calibrated differently, editing a photo by eye may work for your particular monitor, but not necessarily for everyone else. This is also the main culprit behind prints that look drastically different from how an image appeared on your screen. While you should calibrate your monitor if you plan to make a lot of prints, editing for the histogram will at least ensure you can get a print of correct brightness.

Topics
Daven Mathies
Former Digital Trends Contributor
Daven is a contributing writer to the photography section. He has been with Digital Trends since 2016 and has been writing…
Crutchfield sale: Save on Canon, Sony and Nikon mirrorless cameras
Canon EOS R5

Photography can be a fun and even lucrative endeavor, although it also can be exceedingly expensive, with some of the best full-frame cameras on the market easily reaching and even exceeding one or two thousand dollars, and that's without taking into account the cost of the lenses. Luckily, there is a great sale at Crutchfield right now on various cameras and camera kits, and you can actually grab yourself some excellent cameras, whether you're just starting out or want to upgrade to the next level. To that end, we've picked some of our favorite deals below, although it's well worth checking out the full Crutchfield sale that's happenning now.

What you should buy in Crutchfield's camera sale
If you're just starting out with photography and don't want to spend the thousands of dollars you do for the slightly better cameras that you'll find in the mid-range, the Canon EOS R100 is an excellent option, and this kit includes a lens as well. It has a 24.1-megapixel sensor for high-quality photography, a 3-inch screen so you can get a better sense of what you're filming, and, of course, the RF-S 18-45mm f/4.5-6.3 lens that the kit comes with. It can also connect with both Wi-Fi and Bluetooth, and all of that comes packaged at , which is $100 off the usual $599 price tag.

Read more
Save 35% on this SanDisk 128GB SD card for a limited time
The 128GB version of the SanDisk Extreme Pro SD card, on a white background.

When you buy from camera deals, you should also purchase an SD card or two to make sure that you have ample storage for your photos and videos. Unfortunately, the costs will start racking up if you're also going to buy accessories, so you should be on the lookout for offers like this one from StackSocial -- the SanDisk Extreme Pro 128GB for only $20, following a 35% discount on its original price of $31. That's $11 in savings on a dependable SD card, but you'll need to be quick in completing the transaction because there's no telling when the bargain ends.

Why you should buy the SanDisk Extreme Pro 128GB SD card
DSLR cameras and mirrorless cameras usually use SD cards as their storage devices, according to our guide on how to pick the right memory card for your digital camera. If you need one, the SanDisk Extreme Pro is an excellent choice because it offers shot speeds of up to 90 MB/s, which is perfect for recording 4K Ultra HD videos, photos in burst mode, and other types of content that will require a high-performance SD card to keep up with them.

Read more
How to transfer photos from an iPhone to a computer
The Apple iPhone 15 Plus's gallery app.

As the old saying goes, the best camera is the one you always have with you. If you're like most iPhone users, that means you've likely amassed a sizeable collection of photos on your device. However, while Apple's Photos app is a great way to manage and view your photo library, it's never a good idea to keep all your eggs in one basket. After all, suffering a lost or broken iPhone is painful enough without also losing all your precious digital memories in the process.

Even if you're backing up your iPhone to iCloud or your computer, it's a good idea to keep your photos backed up separately. After all, opening a folder or a photo management app is a much easier way to get at your photos than trying to extract them from an iCloud or iTunes/Finder backup, which requires either restoring them to another iPhone or relying on special software tools.

Read more