How Depth of Field Works
Depth of field depends on three primary factors: aperture, focal length, and focus distance. Understanding these relationships helps you control how much of your scene appears sharp.
Aperture (f-stop)
A wider aperture (lower f-number) creates a shallower depth of field, isolating the subject from the background. A narrower aperture (higher f-number) increases DoF, keeping more of the scene in focus.
f/1.4 = very shallow → f/16 = very deep
Focal Length
Longer focal lengths produce shallower depth of field at the same aperture and distance. A 135mm lens has much less DoF than a 24mm lens at the same f-stop and subject distance.
24mm = deep DoF → 135mm = shallow DoF
Focus Distance
The closer you focus to the subject, the shallower the depth of field becomes. At macro distances, DoF can be as thin as a fraction of a millimeter.
0.5m = razor-thin → 50m = very deep
Depth of Field Formula
The approximate total depth of field can be calculated using:
DoF ≈ 2 × N × c × d² / f²
N = f-stop • c = CoC • d = distance • f = focal length
Hyperfocal Distance
The focus distance that maximizes depth of field from half H to infinity:
H = f² / (N × c) + f
Focus at H → sharp from H/2 to ∞
Near Focus Limit
The closest distance that appears acceptably sharp:
Dn = d × (H − f) / (H + d − 2f)
Far Focus Limit
The farthest distance that appears acceptably sharp:
Df = d × (H − f) / (H − d)
When d ≥ H, far limit = ∞