In nanoindentation, the occurrence of cracks, pileup, sink-in, or film delamination adds additional complexity to the analysis of the load–displacement curves. Many techniques and analysis methods have been used to extract both qualitative and quantitative information from the indentation test both during and after the test. Much of this information is obtained indirectly or may even be overlooked by current testing methods (e.g., cracks that open only during the loading cycle of the test may go unnoticed from a typical residual indentation analysis). Here we report on the development of a miniature depth-sensing nanoindentation instrument and its integration into a high-resolution scanning electron microscope. Real-time observation of the nanoindentation test via scanning electron microscopy allows for visualization and detection of certain events such as crack initiation, pileup, or sink-in, and other material deformation phenomena. Initial results from aluminum 〈100〉 and a thin gold film (∼225 nm) are presented.