To overcome the disadvantage of slow f ocusing speed of depth from focus (DFF),a fast auto-focusing algorithm based on improved depth from defocus (DFD) is proposed.Under the condition of only cha nging lens position of the imaging system,a formula to calculate the depth from defocus of target with respect to the blur difference is derived according to t he defocus model of optical imaging system.A spatial-domain convolution/deconvolution transform method (STM) is applied to estimate the blu r difference between the two differently defocused images,and then the depth information of target is calcul ated with the derived formula. Consequently,the lens could be adjusted to finish auto-focusing.The experimenta l results demonstrate that this proposed method only needs two differently defocused images,and can accurately estimate the depth information of target and finish auto-focusing rapidly for a ny target.