The H5N8 avian influenza viruses have been widely circulating in wild birds and are responsible for the loss of over 33 million domestic poultry in Europe, Russia, Middle East, and Asia since January 2020. To monitor the invasion and spread of the H5N8 virus in China, we performed active surveillance by analyzing 317 wild bird samples and swab samples collected from 41,172 poultry all over the country. We isolated 22 H5N8 viruses from wild birds and 14 H5N8 viruses from waterfowls. Genetic analysis indicated that the 36 viruses formed two different genotypes: one genotype viruses were widely detected from different wild birds and domestic waterfowls; the other genotype was isolated from a whopper swan. We further revealed the origin and spatiotemporal spread of these two distinct H5N8 virus genotypes in 2020 and 2021. Animal studies indicated that the H5N8 isolates are highly pathogenic to chickens, mildly pathogenic in ducks, but have distinct pathotypes in mice. Moreover, we found that vaccinated poultry in China could be completely protected against H5N8 virus challenge. Given that the H5N8 viruses are likely to continue to spread in wild birds, vaccination of poultry is highly recommended in high-risk countries to prevent H5N8 avian influenza.