Abstract Uniaxial strain is a powerful tuning parameter that can control symmetry and anisotropic electronic properties in iron-based superconductors. However, accurately characterizing anisotropic strain can be challenging and complex. Here, we utilize a cryogenic optical system equipped with a high-spatial-resolution microscope to characterize surface strains in iron-based superconductors using the digital image correlation method. Compared with other methods such as high-resolution X-ray diffraction, strain gauge, and capacitive sensor, digital image correlation offers a non-contact, full-field measurement approach, acting as an optical virtual strain gauge that provides high spatial resolution. The results measured on detwinned BaFe2As2 are quantitatively consistent with the distortion measured by X-ray diffraction and neutron Larmor diffraction. These findings highlight the potential of cryogenic digital image correlation as an effective and accessible tool for probing the isotropic and anisotropic strains, facilitating the application of uniaxial strain tuning in the study of quantum materials.