Depth of Field Calculator

Stephanie Ben-Joseph headshot Stephanie Ben-Joseph

Introduction: How this depth of field calculator defines sharpness

Depth of field (DOF) is the band of distances around your focus point that will look acceptably sharp in the final image. This depth of field calculator turns that idea into measurable near and far focus limits so you can judge whether a face, a foreground flower, or a distant skyline will stay inside the sharp zone.

Photographers usually think about DOF in terms of creative control:

Use this depth of field calculator when you want to predict whether a subject will feel isolated or anchored in its environment before you take the shot. Instead of relying on guesswork, you can test aperture, focal length, subject distance, and sensor size to see how each choice changes the region of acceptable focus.

Inputs this depth of field calculator uses

The tool relies on four camera settings that shape the size of the sharp zone in a photo:

  • Aperture (f-number) โ€“ A smaller f-number such as f/1.8 opens the lens wider and usually reduces depth of field. A larger f-number such as f/11 or f/16 closes the aperture down and expands the sharp zone.
  • Focal length โ€“ Longer focal lengths, including telephoto lenses such as 85 mm, 135 mm, or 200 mm, tend to make depth of field feel shallower when framing and subject distance are held similar.
  • Subject distance โ€“ Moving closer to the subject reduces depth of field, while stepping back generally gives the calculator a larger sharp range to work with.
  • Sensor size โ€“ For the same framing and aperture, smaller sensors such as APS-C or Micro Four Thirds usually show more depth of field than full frame.

The default values of f/2.8, 50 mm, and 5 m provide a familiar portrait-style starting point on full-frame camera settings. They make it easy to see how the sharp zone changes when you stop down, move the camera, or switch to a different sensor size. If your real setup uses a wider lens, a closer working distance, or a smaller sensor, the calculator will show a different balance between blur and coverage.

Formulas behind the depth of field calculator

To keep the depth of field calculation consistent, the page converts the subject distance to millimetres and works from there. The calculator then combines the chosen circle of confusion, a hyperfocal distance, and the near and far focus formulas to describe the part of the scene that stays within acceptable focus.

Circle of confusion (CoC)

The circle of confusion is the largest blur spot that still appears sharp to a viewer under a typical viewing setup. This calculator uses common approximate values so you can compare formats without needing to tune the model yourself:

  • Full-frame (35 mm): c = 0.03 mm
  • APS-C: c = 0.02 mm
  • Micro Four Thirds: c = 0.015 mm

These values are practical planning numbers, not absolute rules. They are good enough for deciding whether you need more blur, more coverage, or a different focusing distance, but they still assume ordinary viewing conditions rather than a giant print viewed from inches away.

Hyperfocal distance

The hyperfocal distance is the focus distance at which everything from half that distance out to infinity is acceptably sharp for the chosen aperture and sensor size. That makes it especially useful when you want to keep a landscape foreground and a distant horizon both within the depth-of-field calculation:

H = f2 Nโขc + f

where:

  • H is the hyperfocal distance
  • f is the focal length of the lens
  • N is the fโ€‘number (aperture)
  • c is the circle of confusion for the chosen sensor size

Near and far focus distances

Let s be the focus distance to your subject, using the same units as H. The near and far limits that define the depth of field are calculated as:

D_n = Hโขs H+sโˆ’f D_f = Hโขs Hโˆ’sโˆ’f

The total depth of field is then simply:

DOF = Df โˆ’ Dn

If s is greater than or equal to H, the far distance is treated as infinity. That is the familiar hyperfocal behavior landscape photographers often look for when they want the frame to stay sharp all the way to the horizon.

How to interpret the depth of field results

After you run the depth of field calculation, the tool displays four main values that help you judge how forgiving your current focus setup will be:

  • Near focus distance โ€“ The closest point that will appear acceptably sharp relative to the chosen focus point.
  • Far focus distance โ€“ The furthest point that will appear acceptably sharp. In some setups this may be shown as infinity.
  • Total depth of field โ€“ The distance between the near and far limits, which tells you how much of the scene stays inside the sharp zone.
  • Hyperfocal distance โ€“ The focus distance that maximises depth of field from roughly half that distance to infinity.

To use these values in the field:

  • Compare the total depth of field with the thickness of your subject or scene. A narrow DOF may be fine for a face, but not for a product shot with foreground and background details.
  • Check whether the important parts of the composition sit inside the near and far distances. If the eyes are sharp but the nearest hand is not, the calculator has already warned you that the sharp zone is too thin.
  • Adjust aperture, subject distance, or focal length and recalculate until the focus range matches your creative intent and the amount of blur you are willing to accept.

When the far limit reaches infinity, the calculator is telling you that your current focus point is at or beyond the hyperfocal distance. That does not guarantee every leaf or rock will look perfect, but it is a strong clue that the scene is being managed for maximum usable sharpness.

Worked example: a 50 mm portrait at f/2.8

Suppose you are photographing a person on a full-frame camera with a 50 mm lens at f/2.8, and the focus distance is 5 m. Enter those values and choose Full Frame (35mm) for the sensor size.

  • Aperture: f/2.8
  • Focal length: 50 mm
  • Subject distance: 5 m
  • Sensor size: Full-frame

The calculator returns approximately:

  • Near distance: about 4.29 m
  • Far distance: about 6.00 m
  • Total depth of field: about 1.71 m
  • Hyperfocal distance: about 29.81 m

That result says your subject sits inside a fairly shallow sharp zone, which is exactly why a portrait made at this setting often has a pleasing separation between the subject and the background. The focus range is wide enough to cover a person standing naturally, but it is still thin enough that objects much farther away begin to soften.

If you stop down to f/8 and keep the other values the same, the depth of field becomes much larger. Both the near and far limits move outward, so more of the environment stays in focus. This is a practical way to trade background blur for extra detail when you want the surroundings to matter as much as the subject.

Depth of field comparison by sensor size in this calculator

Sensor size affects the result because the calculator uses a different circle of confusion for each format. With the same framing, subject distance, and f-number, smaller sensors generally produce a deeper sharp zone than full frame.

Sensor size Typical CoC used Relative depth of field Practical implications
Full-frame (35 mm) 0.03 mm Shallowest DOF for the same framing and f-number Excellent for strong background blur and subject isolation.
APS-C 0.02 mm More DOF than full-frame at the same framing Easier to keep subjects sharp at moderate apertures.
Micro Four Thirds 0.015 mm Greatest DOF for the same framing Very convenient when you want more of the scene to stay in focus.

When you compare systems, keep the angle of view and subject distance in mind. A smaller sensor may need a shorter focal length to match framing, but the calculator will still reveal how format choice changes the amount of depth of field you get for the same scene. That is why a setup that feels soft on full frame can look noticeably cleaner at the same composition on APS-C or Micro Four Thirds.

Assumptions and limitations of this depth of field calculator

This depth of field calculator is a practical planning aid, not a substitute for checking focus on the camera. It makes several simplifying assumptions so that the output stays easy to interpret:

  • Standard viewing conditions โ€“ The circle of confusion values assume a typical print size and viewing distance. Very large prints or extremely close viewing will make the acceptable-focus zone feel narrower.
  • Still photography โ€“ The model is aimed at single-frame images, not video. Subject movement, camera shake, and motion blur are outside the scope of the calculation.
  • Ideal lens behaviour โ€“ Effects such as focus breathing, field curvature, and unusual rendering characteristics are not modeled. Real lenses can deviate slightly from the geometric result.
  • No diffraction limits โ€“ At very small apertures such as f/16 or f/22, diffraction softening can reduce perceived sharpness even when the geometric depth of field is large.
  • Approximate distances โ€“ Camera-reported focus distances are often rounded. Treat the numbers as estimates rather than exact borders drawn in the scene.

Because of these limits, it is wise to confirm critical focus on your cameraโ€™s display, especially when you are working very close to the subject, trying to hold detail across a deep scene, or relying on a wide-open aperture for selective focus.

How to use the depth of field calculator in practice

Here are some practical ways to make the calculator useful before and during a shoot:

  • Portraits โ€“ Start around f/2 to f/2.8 on full frame, then check whether the near limit still covers the eyes, face, and any slight movement by the subject.
  • Landscapes โ€“ Use the hyperfocal distance result to choose a focus point that keeps foreground texture and distant features acceptably sharp at the same time.
  • Macro โ€“ Expect a very thin depth of field at close distances. Try a smaller aperture, a little more working distance, or focus stacking if the subject has depth that the calculator says you cannot cover in one frame.

The most useful workflow is to change one setting at a time and watch how the near limit, far limit, and total DOF respond. Wider apertures and longer focal lengths reduce the sharp zone; stopping down or backing up usually expands it. If your subject has more depth than the calculator allows, you can decide whether to accept blur, refocus for a different part of the scene, or recompose the shot entirely.

Arcade Mini-Game: Depth of Field Planning Run

Use this quick arcade run to practice spotting which camera settings really shape depth of field and which assumptions can throw off your focus planning.

Score: 0 Timer: 30s Best: 0

Start the game, then use your pointer or arrow keys to catch useful depth-of-field inputs and avoid bad assumptions.

Enter your lens and subject data to see the calculated depth-of-field limits.