HomePhotography & Optics › Hyperfocal Distance Calculator

Hyperfocal Distance Calculator

Computes the hyperfocal distance H = f²/(N·c) + f for a focal length, f-number and sensor circle of confusion, the near limit obtained when focusing at H, and a table of H for the common apertures f/2.8–f/16.

When to use

You want landscape or street settings that keep everything from a near distance to infinity acceptably sharp, or need a focus-distance table for a lens.

Do not use when: You need the sharp zone around an arbitrary focus distance (use depth-of-field), or you want the framing of the lens (use field-of-view).

Formula

H = f² / (N·c) + f (f = focal_length_mm, N = aperture_f, c = coc_mm; result in mm ÷ 1000); near limit = H / 2

Uses the exact definition with the '+ f' term; the common approximation H ≈ f²/(N·c) differs by one focal length. Presets use the diagonal/1500 circle of confusion convention.

Inputs

ParameterTypeUnitRequiredDescription
focal_length_mmnumbermmyesActual (not equivalent) focal length of the lens in millimetres. Range: ≥ 1, ≤ 5000
aperture_fnumberyesLens f-number, e.g. 2.8 for f/2.8. Range: ≥ 0.5, ≤ 128
sensorenum: full_frame | aps_c | aps_c_canon | micro_four_thirds | one_inch | medium_format_44x33 | smartphone_1_over_2_3default full_frameSensor format; selects the circle of confusion used in the formula.
coc_mmnumbermmnoOptional acceptable circle-of-confusion diameter; overrides the preset value (full frame 0.030, APS-C 0.020, Micro Four Thirds 0.015, 1-inch 0.011 mm). Range: > 0, ≤ 1

Outputs

OutputTypeUnitDescription
hyperfocal_mnumbermFocus here for sharpness from H/2 to infinity.
hyperfocal_ftnumberftHyperfocal distance in feet (1 ft = 0.3048 m).
near_limit_when_focused_at_hyperfocal_mnumbermH / 2: closest acceptably sharp distance when focusing at the hyperfocal distance.
coc_used_mmnumbermmCircle of confusion diameter applied (preset or override).
tableobjectmHyperfocal distance in metres for f/2.8, f/4, f/5.6, f/8, f/11 and f/16 with the same focal length and sensor.

Example

24 mm, f/8, full frame: {"focal_length_mm":24,"aperture_f":8,"sensor":"full_frame"}{"hyperfocal_m":2.424,"hyperfocal_ft":7.95,"near_limit_when_focused_at_hyperfocal_m":1.212,"coc_used_mm":0.03}

35 mm, f/11, APS-C: {"focal_length_mm":35,"aperture_f":11,"sensor":"aps_c"}{"hyperfocal_m":5.603,"near_limit_when_focused_at_hyperfocal_m":2.802,"coc_used_mm":0.02}

GET https://tttkmbb.com/api/v1/calculate/hyperfocal-distance?focal_length_mm=24&aperture_f=8&sensor=full_frame

Machine access

Sources

FAQ

Should I focus exactly at the hyperfocal distance?

Focusing slightly beyond H keeps infinity comfortably sharp at the cost of a little near-side depth; focusing short of H makes infinity soft. Lens distance scales are coarse, so err towards the far side.

Does the crop factor change the hyperfocal distance?

Only through the circle of confusion: for the same actual focal length and f-number, an APS-C sensor (c = 0.020 mm) has a hyperfocal distance about 1.5× longer than full frame (c = 0.030 mm).

Related calculators