Home/Calculator Tools/Depth of Field Calculator
📸

Depth of Field Calculator

FREE

Near and far limits of sharpness from lens, aperture and distance

Free · No sign-up required
Loading...

What the depth of field calculator does

Depth of field is the range of distances that appear acceptably sharp in a photograph. Enter the focal length, aperture, focus distance and sensor format, and the calculator returns the near and far limits of sharpness, the total depth of field, and the hyperfocal distance. Use it to know whether both eyes in a portrait will be sharp at f/1.8, how much of a landscape f/11 will hold, or where to focus so everything from a foreground rock to infinity is acceptable. Runs in your browser.

The formulas

Hyperfocal distance H = f² / (N × c) + f Near limit Dn = s × (H − f) / (H + s − 2f) Far limit Df = s × (H − f) / (H − s) (infinity when s ≥ H) Depth of field = Df − Dn f = focal length, N = f-number, s = focus distance, c = circle of confusion c: full frame 0.030 mm, APS-C 0.020 mm, Micro Four Thirds 0.015 mm 50 mm, f/2.8, focused at 3 m, full frame: H = 2500 / (2.8 × 0.03) + 50 = 29,812 mm ≈ 29.8 m Dn ≈ 2.73 m, Df ≈ 3.33 m → depth of field ≈ 0.60 m

What changes depth of field

ChangeEffect on depth of field
Smaller aperture (higher f-number)Deeper — roughly proportional to the f-number
Longer focal length, same distanceShallower — roughly with the square of focal length
Closer focus distanceShallower — roughly with the square of distance
Larger sensor, same framingShallower (the lens is longer or you are closer)
Same lens on a smaller sensor, same distanceSlightly deeper (stricter circle of confusion, but same optics)

Focus distance is the lever people underestimate. A 50 mm at f/2.8 has 0.6 m of depth at 3 m but only 0.07 m at 1 m — which is why close portraits at wide apertures put one eye in focus and the other out.

Worked examples

Setup (full frame)NearFarDoF
85 mm f/1.8, 2 m (head shot)1.96 m2.04 m8 cm
85 mm f/5.6, 2 m1.88 m2.14 m26 cm
35 mm f/8, 3 m (group)1.89 m7.3 m5.4 m
24 mm f/11, 2 m (landscape)0.98 m
200 mm f/4, 10 m (wildlife)9.4 m10.7 m1.3 m
100 mm macro f/8, 0.3 m0.298 m0.302 m4 mm

The circle of confusion

“Acceptably sharp” has to be defined. The convention is a blur spot small enough to look like a point on an 8 × 10 in print viewed at arm's length — about 0.03 mm on a full-frame sensor, scaled down for smaller sensors. High-resolution sensors viewed at 100% on screen are far stricter than this, so pixel-peeping shows less depth of field than the calculator reports. The numbers are a planning guide, not a guarantee of pixel-level sharpness; stop down one extra stop when critical.

Practical use

  • Portraits: f/2.8–f/4 at 2 m with an 85 mm gives 15–25 cm — enough for a face, not a group. Groups need f/8 and everyone in one plane.
  • Landscapes: focus at the hyperfocal distance to get from half that distance to infinity sharp; the Hyperfocal Distance Calculator is dedicated to this.
  • Macro: depth is millimetres; focus stacking is the usual answer.
  • Video: shallow depth looks cinematic but makes focus pulls hard; f/4 is a common compromise.
  • Diffraction: beyond about f/11 on full frame (f/8 on APS-C, f/5.6 on M43) the whole image softens; deeper depth of field trades off against overall sharpness.

Frequently asked questions

Why does the far limit say infinity?

You are focused at or beyond the hyperfocal distance, so everything from the near limit to the horizon is within acceptable sharpness.

Is depth of field split equally in front of and behind the subject?

No. At normal distances about a third is in front and two thirds behind; at close range it approaches half and half; near the hyperfocal distance almost all of it is behind.

Does the calculator work for phones?

Enter the phone's actual focal length (about 6 mm for a main camera) and its sensor's circle of confusion (around 0.005 mm). Phones have enormous depth of field, which is why 'portrait mode' blur is computed rather than optical.

Does a teleconverter change the result?

Enter the combined focal length and the effective aperture (a 1.4× converter adds one stop: f/4 becomes f/5.6).

Why is my photo softer than the calculator predicts?

Camera shake, subject movement, focus error, or viewing at 100% on a high-resolution sensor. The calculator addresses only geometric depth of field.

Are my values stored?

No. The calculation runs in your browser.

More tools in this category

🖼
Aspect Ratio Calculator
Calculate and convert image aspect ratios
🔭
Focal Length Calculator
Full-frame equivalent focal length for any crop factor
Exposure Calculator
Exposure value from aperture, shutter and ISO, with equivalents
🎯
Hyperfocal Distance Calculator
Where to focus for sharpness from half that distance to infinity
🏠
Mortgage Calculator
Calculate monthly mortgage payments and amortization
🏦
Loan Calculator
Calculate monthly loan payments and total interest