Focus Stacking Shot Count Calculator
Calculate how many photos you need for focus stacking.
Find the depth of field per shot and total shots to cover your subject from front to back.
Focus stacking is a technique where you take multiple photos at different focus distances and merge them in software to achieve sharpness across a depth that exceeds what any single lens aperture can deliver.
It is essential for macro photography (extreme close-ups of insects, flowers, coins, food) where depth of field can be less than 1 mm at high magnification.
Depth of field (DoF) per frame formula: DoF = (2 × Nc × Coc × u²) / (f² - Nc × Coc × u)
Where:
- N = aperture f-number
- c = circle of confusion (sensor-dependent)
- u = focus distance
- f = focal length
Circle of confusion by sensor size:
- Full frame (35mm): 0.030 mm
- APS-C (Canon): 0.019 mm
- APS-C (Nikon/Sony): 0.020 mm
- Micro Four Thirds: 0.015 mm
Number of shots needed: Shots = Subject Depth / (DoF per shot × overlap factor)
Using 20–30% overlap between frames ensures no focus gap in the final merge.
Practical steps:
- Set your camera to aperture priority or manual
- Use f/5.6–f/11 for macro (avoid diffraction at f/16+)
- Use a focusing rail for precise incremental focus shifts
- Shoot in RAW for best merge quality
- Use Helicon Focus, Zerene Stacker, or Photoshop’s Auto-Blend Layers
Recommended apertures for stacking:
- Macro (1:1): f/5.6–f/8 for sharpest optical quality
- Close-up (1:3–1:5): f/8–f/11
- Product photography: f/8–f/16
- Avoid f/22+ — diffraction softens images significantly
Software options:
- Helicon Focus (paid, excellent for macro)
- Zerene Stacker (paid, great for insects)
- Adobe Photoshop (Edit → Auto-Blend Layers → Stack Images)
- Affinity Photo (free on promotion, good results)