The positioning function of unmanned aerial vehicles (UAVs) is a challenging and fundamental research topic and is the premise for UAVs to realize autonomous navigation. The disappearance of satellite signals makes it challenging to achieve accurate positioning. Thus, visual positioning algorithms based on computer vision have been proposed in recent years and these algorithms have produced good results. However, these algorithms have relatively simple functions and cannot perceive the environment. Their versatility is poor, and mismatching often occurs, which affects the positioning accuracy. Aiming to address the need for integrated target recognition, target matching, and positioning of UAVs, we propose an algorithm that integrates the target recognition, matching, and positioning functions by combining the single-shot multibox detector (SSD) algorithm with the deep feature matching algorithm. This algorithm is based on the idea of pseudo-Siamese networks and the SSD algorithm, introducing a deep feature matching method to directly calculate the correspondence between two images. The main idea is to use the VGG network trained by the SSD target recognition algorithm to extract deep features, without any special training for feature matching. Finally, by sharing neural network weights, the integrated design of target recognition and image-matching localization algorithms is achieved. Mismatches between the real-time and reference images are addressed by introducing the grid-based motion statistics algorithm to optimize the matching result and improve the correct matching efficiency of the target. The University-Release dataset was used to compare and analyze the performance of the proposed algorithm to verify its superiority and feasibility. The results show that the matching accuracy of the PSiamRML algorithm is generally good and that it significantly compensates for changes in the contrast, scale, brightness, blur, deformation, and so on, apart from improving the stability and robustness. Finally, a matching test scenario with aerial images captured by an S1000 six-rotor UAV served to verify the effectiveness and practicability of the PSiamRML algorithm.