Introduction
This depth of field calculator shows you how much of your photo will look sharp. You pick your camera, lens, f-stop, and focus distance. It then tells you the near limit, the far limit, and the total depth of field.
Depth of field is the zone in front of and behind your subject that still looks in focus. A wide aperture like f/1.8 makes that zone thin, so the background goes soft. A small aperture like f/16 makes it deep, so more of the scene stays sharp. Your sensor size, focal length, and how close you stand change it too.
The tool also gives you the hyperfocal distance, which is the best spot to focus when you want everything from halfway out to the horizon to be sharp. That is handy for landscapes, real estate, and street photos.
The calculator draws a diagram of your sharp zone, shows the math step by step, and plots a chart of depth of field at every f-stop. In Advanced mode you can set your own circle of confusion, add a teleconverter, check background blur, and see when diffraction starts to soften your image. You can also work backward and ask which f-stop gives you the depth of field you want.
How to use our Depth of Field Calculator
Tell the calculator about your camera, lens, aperture and focus distance. It gives you the near and far limits of sharp focus, the total depth of field, the hyperfocal distance, background blur, field of view and diffraction limits, plus diagrams and step-by-step math.
Calculator Detail Level: Pick Basic for the main inputs only. Pick Advanced to unlock background blur, circle of confusion options, framing tools and diffraction.
Unit System: Choose Metric or Imperial. This switches your distance boxes to meters or feet.
Calculation Direction: Use Standard to find depth of field from your f-stop. Use Inverse to find the f-stop that gives the depth of field you want.
Camera Make: Pick your camera brand. This filters the model list. You can skip it and pick a sensor instead.
Camera Model: Pick your camera. The sensor size, crop factor and circle of confusion are set for you.
Sensor / Film Format: Pick your sensor or film size if your camera is not listed. Bigger sensors give shallower depth of field at the same framing.
Crop sensor to 16:9 (video): Tick this if you shoot video in a 16:9 frame. It trims the sensor area and changes the field of view.
Focal Length: Type the real focal length printed on your lens in mm, not the 35mm equivalent. Longer lenses give less depth of field.
Aperture (f-number): Pick the f-stop you are shooting at. Low numbers like f/1.4 blur the background more.
Aperture Steps: Choose whole, half or third stops to match the clicks on your lens or camera dial.
Lens Converter: Pick a teleconverter, focal reducer or anamorphic adapter if you use one. Or choose Custom and type your own multiplier.
Focus / Subject Distance: Type how far your subject is from the camera, then pick the unit. This is measured from the sensor, not the front of the lens.
Background Distance: Type how far the background is from the camera. The tool uses this to work out the blur circle size behind your subject.
Lock background distance: Tick this to keep the background in the same spot when you change your subject distance.
Scale background with subject distance: Tick this to move the background with you and keep the same subject-to-background ratio.
Display Results In: Pick the unit for all your results. A second unit is shown in brackets.
Desired Total Depth of Field: Only used in Inverse mode. Type the sharp zone size you want and the tool finds the f-stop you need.
CoC Method: Choose how strict the sharpness standard is. Auto uses your sensor preset; you can also enter a value in mm, a diagonal divisor, pixel or megapixel counts, print size and DPI, or display size and viewing distance.
Framing Presets: Click a preset like Portrait or Full body to set a matching focal length and distance in one tap.
Lock field of view: Tick this to keep your framing the same. Then choose whether the distance or the focal length adjusts when you change the other.
Diffraction Analysis: Tick this to see the Airy disk size, the sharpest aperture and the smallest f-stop you can use before blur creeps in.
Calculate, Reset and Print Summary: Results update as you type, but click Calculate to refresh. Reset returns every field to the default. Print Summary lays the results out as a table you can print.
What Is Depth of Field?
Depth of field (DoF) is the zone in your photo that looks sharp. It starts at the near limit, runs through the point you focused on, and ends at the far limit. Things closer than the near limit or farther than the far limit look blurry.
A shallow depth of field makes a small sharp zone. That is great for portraits, where you want a soft, blurry background. A deep depth of field makes a big sharp zone. That is great for landscapes, where you want the rocks up front and the hills far away to both look clear.
What Changes Depth of Field
- Aperture (f-number). A big f-number like f/16 means a small hole in the lens, so more of the scene is sharp. A small f-number like f/1.4 means a wide hole and a thin sharp zone.
- Focal length. Long lenses (200mm) give a thin sharp zone. Wide lenses (16mm) give a deep one.
- Focus distance. The closer you stand to your subject, the thinner the sharp zone gets. Macro work has a razor-thin zone, often just a few millimeters.
- Sensor or film size. A big sensor, like full frame or medium format, gives a shallower look than a small phone sensor when the framing matches.
Circle of Confusion
Only one plane in a photo is truly sharp. Everything else is a tiny blur dot. The circle of confusion (CoC) is the biggest blur dot your eye still reads as a sharp point. If the dot is smaller than the CoC, the spot counts as "in focus."
The usual rule is the sensor diagonal divided by 1500. A full-frame camera lands near 0.029mm. You can also set the CoC from your pixel size, your print size and DPI, or how far away people will stand when they view the picture. A smaller CoC is a stricter test, so the sharp zone gets smaller.
Hyperfocal Distance
The hyperfocal distance is a special focus point. Focus there and everything from half that distance out to infinity looks sharp. It is the trick landscape shooters use to get the most depth from one shot. The math is:
H = (f × f) ÷ (N × c) + f
Here f is focal length in mm, N is the f-number, and c is the circle of confusion in mm.
The Sharp Zone Is Not Even
Depth of field does not split evenly around your subject. More of it falls behind the subject than in front. At normal distances the split is close to one third in front and two thirds behind. Up close it moves toward 50/50, and far away almost all of it sits behind the subject. So when you focus for a group of people, aim at the front row, not the middle.
Background Blur and Bokeh
Blur strength depends on how far the background sits behind your subject, plus your focal length and aperture. A longer lens, a wider aperture, and a far-away background all make blur bigger. Blur is measured as the size of the blur disc in millimeters on the sensor.
Diffraction: Why f/22 Is Not Always Best
Closing the aperture adds depth of field, but it also bends light at the edges of the blades. This is diffraction, and it spreads each point of light into a small ring called an Airy disk. Its size is about 2.44 × λ × N, using green light at 0.00055mm.
Past a point, diffraction blur costs you more sharpness than the extra depth of field gains. Small sensors hit that wall sooner than big ones. Most cameras do their best work a few stops down from wide open, often around f/5.6 to f/8 on full frame.
Crop Factor and Equivalent Settings
Crop factor compares a sensor to full-frame 35mm. Multiply your focal length by the crop factor to get the 35mm equivalent view. Multiply the f-number by the same crop factor to get the aperture that would give the same depth of field on full frame. A 25mm f/1.8 lens on Micro Four Thirds (2× crop) frames and blurs like a 50mm f/3.6 lens on full frame.
Quick Tips
- Want a blurry background? Open the aperture, use a longer lens, get closer, and move your subject away from the wall.
- Want everything sharp? Close the aperture, use a wider lens, back up, and focus at the hyperfocal distance.
- Measure focus distance from the sensor plane, not the front of the lens.
- For macro shots, the plain formula gets loose. Use the close-focus correction, since magnification makes your real aperture darker and the sharp zone thinner.