In view of the problems that current high proportion of manual operations for virtual glasses try-on, single try-on angle, distorted try-on effect, and low commercial rate of try-on technology, a virtual try based on the combination of facial feature detection and head space pose estimation is proposed, and a virtual glasses try-on system is implemented. The real-time videos of the head are collected through the camera and analyzed by frame, and ERT cascade regression is used to locate facial feature points. According to the position information of the facial feature points and the head rotation information, the perspective-transformed eyeglass image is accurately integrated into the face image at the corresponding angle. The 3D real-time pose estimation is quantitatively evaluated on the AFLW face database, and the angle error within ±60° is about 8.8°. The results show that the algorithm has high precision and fast speed, and can quickly and accurately realize 3D multi-angle virtual try-on in complex situations with frequent angle changes, large changes in external light intensity, and many background interferences.The effect obtained by the algorithm is realistic and natural, and basically meets the requirements of virtual try-on technology.