Have you ever tried taking a close up photo of a beautiful flower using a telephoto lens and realized after focusing that most of the flower is still blurry due to depth of field?
It’s a challenge because you often need a wide open aperture in order to let enough light in to get the shot without too much noise but doing so also means a very shallow depth of field when what you really want is a large depth of field.
This doesn’t only apply to close up photos of flowers and such either. This technique can also be used in landscape photography in order to maximize the depth of field without suffering the diffraction effects of stopping the aperture right down to f/32 or something.
How to focus stack
In order to maximize the depth of field without stopping the aperture right down you need to take a series of photos at a shallower depth of field and then use software to analyze the images, align them and stack the sharpest focused regions of each image on top of each other.
Take this series of images of a drill bit.
I wouldn’t recommend shooting a stack at f/2.8 like I did here. I mostly did this for illustration purposes. That said, you can certainly do it and it does stack nicely if you’re using good software for doing it.