🎯 Depth of Field Calculator

Calculate near/far focus limits, DOF, and hyperfocal distance.

β€”m

Total Depth of Field

How to Use This Calculator

Select your camera sensor, enter the focal length of your lens, set the aperture you plan to shoot at, and type in the distance from your camera to the subject. The calculator instantly shows the total depth of field, hyperfocal distance, and the near and far limits of acceptable sharpness.

1

Choose your camera sensor from the dropdown. The circle of confusion (CoC) fills in automatically, or you can type a custom value.

2

Enter your focal length in mm. A 50mm lens on full frame gives a "normal" look; 85mm and up is great for portraits.

3

Set the aperture. Wide apertures like f/1.8 or f/2.8 give you that blurry background. Smaller apertures like f/8 or f/11 keep more of the scene sharp.

4

Type in the subject distance in meters. For a headshot at arm's length, try 1.5 to 2 meters. For a full-body portrait, try 3 to 5 meters.

Depth of Field Formulas

H = fΒ² / (N Γ— c) [hyperfocal distance] Near = DΓ—(Hβˆ’f) / (H+Dβˆ’2f) [nearest sharp point] Far = DΓ—(Hβˆ’f) / (Hβˆ’D) [farthest sharp point] DOF = Far βˆ’ Near f = focal length (mm), N = f-number, c = CoC (mm), D = focus distance (mm)

H is the hyperfocal distance β€” the focus point that puts infinity at the edge of acceptable sharpness. N is the f-number (like 2.8 or 8). C is the circle of confusion, which depends on your sensor size. D is how far away your subject is. When your focus distance equals or exceeds H, the far limit becomes infinity and everything beyond the near limit looks sharp.

Real-World Examples

Portrait: 85mm f/1.8, 2m, full frameDOF β‰ˆ 4 cm
Street: 35mm f/5.6, 3m, APS-CDOF β‰ˆ 1.4 m
Landscape: 24mm f/8, 5m, full frameDOF β‰ˆ ∞ (past hyperfocal)
Group photo: 50mm f/4, 4m, full frameDOF β‰ˆ 1.3 m

When You Need This

Knowing your depth of field before you shoot saves a lot of time on location. When you're photographing a wedding portrait and the background is a cluttered street, you need to know whether f/2.8 at your shooting distance will actually separate your subject. Too close to hyperfocal and that background stays distractingly sharp. Check the near and far limits and reposition yourself if needed.

For product or food photography in a studio, you often want the opposite: a very precise zone of sharpness so the camera angle doesn't accidentally throw a detail out of focus. Dial in your aperture here first, confirm the DOF covers everything you need, and then set up your lights. Changing the f-stop after lighting is set means redoing your exposure math, so get the DOF locked in at the start.

Frequently Asked Questions

What is depth of field?

Depth of field (DOF) is the range of distances that appear acceptably sharp in a photo. A shallow DOF blurs the background (bokeh effect). A deep DOF keeps everything sharp.

What factors affect depth of field?

Three main factors: aperture (wider = shallower DOF), focal length (longer = shallower), and subject distance (closer = shallower). Sensor size also affects DOF β€” larger sensors produce shallower DOF at the same settings.

What is the hyperfocal distance?

The hyperfocal distance is the closest focus point at which infinity is still acceptably sharp. Focusing at the hyperfocal distance maximizes DOF. H = fΒ²/(NΓ—c) where c is the circle of confusion.

What is the circle of confusion?

The circle of confusion (CoC) is the maximum acceptable blur spot size for an image to appear sharp. It depends on sensor size and viewing conditions. Typically 0.029–0.033mm for full frame, 0.019mm for APS-C.

How do I get more background blur (bokeh)?

Use a wide aperture (small f-number like f/1.8), a longer focal length, get closer to your subject, and increase the distance between subject and background.