Depth of Field in Macro Photography

Erez Marom | Photo Techniques | Published Feb 15, 2012

One of the greatest challenges for macro photographers is achieving sharp focus for all of the scene's important elements. In this image the wings of only one of this pair of caper whites are in focus.

The defining characteristic of macro photography is of course that subjects are shot at close distances. While this close camera-to-subject proximity can lead to visually arresting images captured from an intimate perspective, this sort of photography presents unique technical challenges as well.

In this article I'll address one of the most significant of these challenges - controlling depth of field (DOF). The term depth of field refers to the area in front of and behind the point on which focus is set that can be rendered in sharp focus. As we'll explore throughout this article, DOF control plays a very prominent role in macro photography.

The cute creature in the image below is a cicada nymph, by definition the larval or sub-adult stage of an insect with partial metamorphosis. For me, this image is a failure. Why? Almost all the interesting parts and features of the nymph are are out of focus - its abdomen, wing buds, legs, even the front of its head.

In this image of cicada nymph , satisfyingly little of the subject is rendered in sharp focus.

Why are so many of the image elements blurred? It's not due to poor focusing technique. If you look carefully, you’ll see that I placed focus on the cicada's eye, always a good choice whether photographing people or insects. The lack of sharp detail results from insufficient DOF. That is, the range of objects in front of and behind my point of focus that can be simultaneously rendered in sharp focus is extremely shallow. The result? We see sharp detail in just a tiny portion of the whole image.

Here's another example of shallow DOF. When focus is placed on the mantis’ eye, the rest of its body is out of focus. As you can see, the problem isn't solved simply by focusing on another area. If I place focus on the rest of the head area, the is eye then out of focus.

Understanding depth-of-field

Before we can begin to figure out how to better control DOF, we must first understand the factors that make it so problematic in macro photography. Depth of field is dependent upon three factors: aperture value, focal length and subject distance. When each of the other two variables are fixed, setting a larger F-stop number (which actually means a smaller aperture opening) will result in a larger DOF. Using a longer focal length will result in a smaller DOF. And shooting at a closer subject distance means a smaller DOF.

In macro photography, however, DOF depends primarily on just two factors: aperture value and magnification. At any given aperture value, the higher the magnification ratio, the smaller the DOF. And this explains why DOF is so shallow in macro;  the magnifications are simply much larger than in any other type of photography.

With this in mind, let's go back to the cicada image that began this discussion. When photographers see such a shallow DOF, they instinctively think the aperture was set very wide (a small F-stop number). But this shot was made at f/9.0 which, outside of macro photography, is considered to be a narrow aperture. That leaves magnification as the main contributor to shallow DOF. This nymph is only 2 or 3mm in length, and since I wanted to photograph it filling a large portion of the frame, I had to use an extreme magnification ratio – in this case, of 5:1, meaning that the cicada's projection on the sensor was 5 times its actual size! Extreme indeed, and so DOF is extremely shallow, at only a fraction of a millimeter.

One might think that a too-shallow DOF appears only in extreme macro. This is
not true: even in this image of a devil’s horse nymph, shot using a magnification
much lower than 1:1, a larger DOF would definitely be welcome.

Since DOF is affected by aperture and magnification, let's see what happens when we alter them. First - aperture value. The robber fly below was shot using a very small aperture: f/16. In fact, this aperture is so small that is causes a significant loss of sharpness due to diffraction. And it still doesn’t help this image much; the DOF is too shallow with most of the subject out of focus.

Here, even a very small aperture couldn’t help making the DOF large
enough to have the whole subject in focus.

The second thing that can be done is to lessen the magnification by stepping back from the subject and making it take up less space in the frame. This most certainly works to increase DOF. Yet I have two major problems with this 'solution'. Having the subject fill a smaller part of the frame than intended forces you to crop the image in post processing. And while a large  crop may make the subject appear as if you shot it at closer range, you end up with less detail, eliminating one of the most appealing aspects of macro photography.

Furthermore, as a wildlife photographer I always wish to capture my scene in as close a state as possible to the final image. Using a small magnification and then making a significant crop collides with this ideal and personally I avoid this unless there is simply no other choice.

 So what can be done? On the next page I'll show you two different ways to tackle the problem.

Adjusting composition for greater depth-of-field

Take a look at the image below. In comparison to the robber fly image we discussed on the previous page, this fly was shot using both a wider aperture and at a higher magnification ratio. This means beyond doubt that DOF is smaller. Yet, the image doesn’t lack for greater DOF. Almost the entire fly is in focus.

The difference here is that the subject was shot from a direction which enabled me to fit most of its interesting parts along a single plane of focus. Remember that DOF controls how far in front of and behind the point of focus can be rendered in sharp focus. Yet all points in the scene that exist at the same distance from the lens can be in focus simultaneously, no matter the amount of DOF available. What I've done here is to carefully position the camera so that all of the parts I want to be in focus fall along a plane that is parallel to and therefore equidistant from the lens. The fly’s side is relatively flat, so by adjusting the camera lens to be parallel with the fly's body, I managed to get sharp focus on all of the body parts which stand out the most.

A fly shot from the side. All important parts are in focus, even though DOF is extremely shallow.

It’s very important to understand that we have not extended DOF. It is still extremely shallow. Look at the fly’s front right leg. It’s only a millimeter behind its front left leg, but still out of focus. Shallow DOF is also visible in the wings. The section closest to the viewer is focused, the part farther away is out of focus. The point is that although DOF is shallow, if the subject is flat enough we can shooting at an angle parallel to the subject and produce an image with satisfying focus.

While this method might seem very basic, it’s by far the easiest and most common method of dealing with the DOF problem in macro, and is definitely the first method I teach all students. It’s easy to use – just remember to be parallel to the subject’s body. Since arthropods usually have at least one flat side, this method is very effective with a wide range of subjects.

Let's examine another image. The Levantine leopard (Apharitis acamas) shown below was shot using an aperture of  f/8 - which is relatively wide for macro work - but still I managed to get focus from head to abdomen, including the wings. When shooting butterflies it’s important to remember that one needs to be parallel not along the right-left axis (with both head and abdomen existing at the same distance from the sensor), but also along the up-down axis (with both body and wings at the same distance from the sensor).

Butterflies have very flat bodies. This makes shooting them from a parallel angle very effective for maintaining focus over the entire body.

Faking depth-of-field: Focus Stacking

So problem solved, right? Well, not quite. What happens if we don’t want to shoot parallel to the subject? It’s extremely limiting to constrain our shooting angle this way every single time we photograph. Sometimes we want to view the subject at a frontal angle or even a diagonal. And of course some subjects have such irregular shapes that they have no flat side! Think of protruding body parts such as antennae, a proboscis and wings.

This robber fly has no flat side,
and so shooting it from a parallel
angle is not a viable option. Here
the eye is in focus, but little else.
Another shot, this time with focus
on the mustache and proboscis,
but now the eye is out of focus.

Luckily, the digital revolution has brought a very efficient method of actually increasing DOF. It is called 'focus stacking' and I’ll be covering it in detail in an upcoming article. Simply put, focus stacking is a process that involves two stages. First, in the field, you shoot a series of images with identical composition, each focused on a plane of different depth on the subject’s body. For example, one shot can be focused on the eye, the other on the proboscis, and so forth. You shoot as many images as you need. The main rule is that every part of the subject you want to appear sharp in the final image must exist in sharp focus in at least one image of the series. 

By combining the images above via focus stacking, we achieve a result
that has both detail and sufficient DOF.

Next, in the comfort of your home, you can use any number of software programs which automatically select the focused parts of each image and stack them together - hence then term 'focus stacking' - into a composite image that exhibits a wider DOF than you could ever hope to capture in a single exposure. 

Focus stacking is a fantastic innovation for the macro photographer. And while it does take more time and careful preparation in the field, there just isn’t a better way of obtaining both detail and increased DOF in extreme magnifications.

A praying mantis portrait, created by stacking two images. Without focus stacking, either the mouth parts or the eyes would have been out of focus.

With these new tools in hand I don't want to leave you with the impression that shallow DOF is inherently bad. On the contrary, it is one of the most effective compositional tools at our disposal. By purposefully using shallow DOF you can create a dramatic appearance and lead the viewer’s attention to specific elements in the scene, control that is critical to success in every style of photography.

For further reading on macro photography take a look at Erez's previous articles in this series:

The what and why of wildlife macro photography
What we want in a macro shot - Detail
What we want in a macro shot - Background
What we want in a macro shot - POV and special scenes
Macro photography: Understanding magnification

Erez Marom is a professional nature photographer and photography instructor based in Israel.
Erez will lead a macro and nature photography workshop in Costa Rica in July 2012, where he will explain his photography techniques and methods with which he achieves his unique results. Registration is open for this unique opportunity to learn first hand from one of the world's leading macro artists.

You can see more of his work at www.erezmarom.com and follow him on his Facebook page and 
deviantArt gallery.