Recently, the research on the vehicular ad hoc network (VANET) has been paid more attention by researchers with the quick development of the autonomous driving technology. In the VANET, vehicles can communicate with everything through the route established by routing algorithms. However, the topology of the VANET changes fast because the vehicles move fast. Also, as the number of vehicles increases, the probability of data collision and the transmission latency will also increase when communicating. Therefore, the VANET needs a stable, low-latency, and efficient route for vehicles to communicate with each other. However, the existing routing algorithms are either unable to aggregate data or are not suitable for the large-size VANET. In this paper, we consider the vehicle attribute information comprehensively and cluster the vehicles on the road by using the cluster algorithm we propose. We dynamically select the cluster heads at each moment according to their attribute information. We consider all kinds of nodes in the network and the vehicle nodes will communicate with each other through the cluster heads under the two-level communicating algorithm we propose. Compared with the existing cluster routing algorithm, the algorithm we propose is much more suitable for the large-size VANET because the cluster heads do not need a gateway to help them communicate. In the simulation part, we set some real street scenes in Simulation of Urban Mobility (SUMO) and the vehicles can move by the traffic rules like in the real world, which is more suitable for the VANET. After analysing the communication performance in Network Simulator version 2 (NS2), we can get a conclusion that the algorithm proposed is superior to the traditional routing algorithm. The route established by the algorithm we propose is much more stable and efficient. And the latency is also lower than the former.