With the quick development of Internet of Things (IoT), one of its important supporting technologies, i.e., wireless sensor networks (WSNs), gets much more attention. Neighbor discovery is an indispensable procedure in WSNs. The existing deterministic neighbor discovery algorithms in WSNs ensure that successful discovery can be obtained within a given period of time, but the average discovery delay is long. It is difficult to meet the need for rapid discovery in mobile low duty cycle environments. In addition, with the rapid development of IoT, the node densities of many WSNs greatly increase. In such scenarios, existing neighbor discovery methods fail to satisfy the requirement in terms of discovery latency under the condition of the same energy consumption. This paper proposes a group-based fast neighbor discovery algorithm (GBFA) to address the issues. By carrying neighbor information in beacon packet, the node knows in advance some potential neighbors. It selects more energy efficient potential neighbors and proactively makes nodes wake up to verify whether these potential neighbors are true neighbors, thereby speeding up neighbor discovery, improving energy utilization efficiency and decreasing network communication load. The evaluation results indicate that, compared with other methods, GBFA decreases the average discovery latency up to 10.58% at the same energy budget.