Time-dependent second harmonic generation (TD-SHG) is an emergent sensitive and non-contact method to qualitatively/quantitively characterize the semiconductor materials, which is closely related to the interfacial electric field. Here, the TD-SHG technique is used to study the interface quality of atomic layer deposited 15 nm HfO2/Si (n-type/p-type) samples, which is compared to the conventional electrical characterization method. A relation between the interface state density and the time constant extracted from TD-SHG is revealed, indicating that TD-SHG is an effective method to evaluate the interface state density. In addition, the dopant type and dopant density can be disclosed by resolving the dynamic process of TD-SHG. The scenario of interfacial electric field between the initial electric field and the laser-induced electric field is proposed to explain the time-dependent evolution of SHG signal. In conclusion, the TD-SHG is a sensitive and non-contact method as well as simple and fast to characterize the semiconductor materials, which may facilitate the semiconductor in-line testing.