A binary artificial rabbit optimization algorithm is proposed to maximize the cognitive radio (CR) network performance and fairness among users by addressing the issue of low spectrum resource utilization during the CR spectrum allocation process. Building upon the graph coloring spectrum allocation model, Sigmoid is introduced to transform the algorithm solution space. Incorporating the Lévy flight strategy for adaptive step size adjustment enhances the algorithm’s flexibility and convergence accuracy. Moreover, a selective opposition strategy based on Spearman’s coefficient is integrated into the algorithm to improve population diversity and convergence accuracy through reverse learning. Applying the binary artificial rabbit optimization algorithm to the CR spectrum allocation problem in the same CR network environment, we compare network efficiency and inter-user fairness through simulation experiments with the artificial rabbits optimization algorithm seagull optimization algorithm and particle swarm optimization algorithms. The experimental results show that the binary artificial rabbit optimization algorithm has higher convergence performance and global exploration ability, improves the overall network efficiency and user fairness of CR networks, and alleviates the problem of low spectrum resource utilization.