Cognitive radio (CR) technology is beneficial for unmanned aerial vehicles (UAVs) to access the spectrum resources needed for communication. Then, in order to integrate CR technology into UAVs without causing excessive interference to the primary users (PUs), cooperative spectrum sensing (CSS) is used as a key function of CR technology to detect the PUs for the UAV's available spectrum. However, the flexible locations of UAVs may significantly degrade the performance and efficiency of CSS within them. Hence, on the basis of a cognitive UAV networks (CUAVN) framework, we propose an internal cooperation paradigm to achieve the cooperative gain of CSS within an UAV. Furthermore, we convert the decision rule as an optimal stopping problem to optimize the decision rule for CSS. The optimization problem is carried out by the error probability regarding the PU presence of the phenomenon and the stopping time required to reach a global decision about the PU status. By optimizing the error probability respectively under the condition of a fixed sensing time, the optimization problem is transformed into an optimal stopping problem and solved by Markov stopping theory. Following this, we further determine a pair of thresholds in the optimal sequential decision rule from the minimal cost function. At last, numerical simulation results verify the correctness and effectiveness of the optimal sequential detection rule, and corroborate that in contrast to the external cooperative paradigm, the superiority of the internal cooperative paradigm under various network environments and parameters, in terms of the CSS performance and the stopping time.