In cognitive radio (CR) networks, secondary users can cooperatively sense the spectrum to detect the presence of primary users. In this paper, we propose a fully distributed and scalable cooperative spectrum-sensing scheme based on recent advances in consensus algorithms. In the proposed scheme, the secondary users can maintain coordination based on only local information exchange without a centralized common receiver. Unlike most of the existing decision rules, such as the or-rule or the 1-out-of-N rule, we use the consensus of secondary users to make the final decision. Simulation results show that the proposed consensus scheme can have significant lower missing detection probabilities and false alarm probabilities in CR networks. It is also demonstrated that the proposed scheme not only has proven sensitivity in detecting the primary user's presence but also has robustness in choosing a desirable decision threshold.