We have developed a scanning micro-mirror with an adjustable focal length for endoscope applications. With active focus tracking capability, it allows high-resolution 3D imaging to be achieved with the endoscope system, which can significantly improve the currently limited ability for detecting early and pre-cancers.