Points in Focus Photography

Focus Stack Calculator

This calculator computes the number of frames needed to make a focus stack with a focus shift specified in the focus step field that covers from the starting distance to the ending distance.

Please note, this calculator is still in beta and may not provide accurate results in all conditions.

Direct link


Distance Units
500 millimeters
500 mm millimeters
5m meters
30.6” inches
3’ feet
3.6’ feet
3’4” feet and inches

To use the calculator enter your lens’s focal length, the aperture you will be shooting at, whether or not you have the camera set to APS-C crop mode, the focus step size you’ve set, and the starting and ending distances for the stack you want to shoot.

Distances are a free form number that’s parsed by the script and can be specified in either feet, inches, feet and inches, meters, or millimeters. See the following table for examples

Assumptions and Theory

I’ve made two major assumptions in the development of this too. First relates to the size of the focus shift between images. Canon calls this “focus increment” on cameras such as the EOS R5. Nikon calls this “Focus step width” on cameras such as the Z6 II and Z7 II. My assumption at the present time is that the focus steps are equal to 1/8 of a depth of field.

I made this assumption for two reasons. First, 1/8 of a depth of field has historically been the size of the smallest AF increment available on Canon cameras. It’s what an AF micro adjustment step was, as well as the smallest shift you could make when remotely controlling the focus via Canon’s EOS Utility.

I’m fairly confident in the accuracy of this assumption, as in my testing a focus increment of 8 on my EOS R5 corresponds to a focus shift that’s approximately 1 depth of field deep.

The second assumption deal with the acceptable threshold for the depth of field. Namely I’m using the same standard that most camera manufacturer’s use when they calculate depth of field. This formula can be traced back to film photography and in some respects may be insufficient for modern high resolution digital cameras — at least in some applications.

With those assumptions in hand, I calculate the depth of field for the specified lens, aperture, crop size, and initial (close) focus distance. Then shift the focus position towards infinity by “focus step” × 1/8 of that depth of field. This process is repeated until either infinity is reached, 999 steps have been taken, or the specified far depth of field limit has been reached.


Wim Vanmaele


I tried your webapp. It is not working.
I can’t choose an aperture. Dropbox doesn’t open, no value is selectable.

If needed, I can, will help you in coding this (if it is php)

Otherwise, nice thing to have, use.

    Jason Franke  | admin

    Sorry about that, boneheaded move on my part, I didn’t properly link a required JavaScript file for production.

    It should work now.

Wim Vanmaele

Sorry, but it is not working.
When I check the JS, no values are available in the combobox ‘Aperture’. Maybe there is a mistake in the name ? Using or not using a captial ?
On the HTML-page, normally, in a dropdown (select) possible options are added. They are missing here.

select id=”aperture” class=”updtrig” name=”aperture” data-mini=”true” style=”width:5em”

Should be:

option 1
option 2

    Jason Franke  | admin

    1) What browser are you using? (Try a different one if you have another installed.)
    2) Are you running a content/ad blocker? (I don’t actually care if you do, but make sure that it’s not blocking scripts from http://www.pointsinfocus.com, static1.pointsinfocus.com, or jquery from cdnjs.cloudflare.com)
    3) Have you flushed your browser’s cache and reloaded the page? (The HTML is the only thing that changed, and that shouldn’t be cached. Loading the page with the developer console open should also force the browser’s cache to be ignored.)

    The contents of the Aperture select box are generated by the JS doing the calculations. If it’s not generating then the odds are that there’s a JS error that’s causing the execution of the scripts to halt/fail to execute. Check your JS console, and see what warnings are showing up. Unfortunately, I can’t seem to reproduce the problem on my end, and I’ve tested the page in Chrome (win & macos), Edge, Firefox, and Safari (macos & ios).

    I’d like to get to the bottom of this if I can, as I do consider this to be in beta; so it’s possible that there’s a bug I’m simply not seeing and I’d like to fix that.

Leave a Reply

Basic Rules:
  • All comments are moderated.
  • Abusive, inflamatory, and/or "troll" posts will not be published.
  • Links to online retailrs (eg., Amazon, Ali Express, EBay, etc.) either directly, or indirectly through 3rd party URL shorternrs, will be removed form your post.
  • Extremely long comments (>1000 words) may be blocked by the spam filters automatically.
  • If your comment doesn't show up, it may have been eaten by the spam filters; sorry about that.
  • See the Terms of Use/Privacy Policy for more details.

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Follow me on twitter for updates on when new comments and articles are posted.

Email Notice Details: By checking the above checkbox, you are agreeing to recieve one email at the email address provided with this comment, for the sole purpose of notifing you that the article author has been reseponded to your comment.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Our cookie and privacy policy. Dismiss