Plastic film mulching (PFM) can influence soil nutrients, thereby improving plant growth and yield in vast dryland areas. However, it is unclear how PFM treatment affects soil microbial communities, especially with respect to community diversity, assembly processes, and co-occurrence patterns in multiple sites. In the present study, we explored the effects of traditional flat planting (TP) and PFM on the crop yield as well as the soil quality, bacterial and fungal diversity, community composition, assembly processes, and co-occurrence networks in broomcorn millet (Panicum miliaceum L.) fields in northern China. The results showed that compared with TP, PFM significantly enhanced soil hydrothermal conditions and soil nutrients, thereby improving the agronomic characteristics and yield of broomcorn millet in the nine study sites. Furthermore, PFM significantly reduced the fungal alpha diversities and changed the fungal community composition and relative abundances of some bacterial and fungal taxa. Random forest (RF) analysis indicated that fungal alpha diversity, soil temperature, and pH were the most important factors affecting broomcorn millet yield. PFM decreased the stochastic processes of the fungal community, also reduced the complexity and stability of the bacterial and fungal networks, which was reflected in the lower number of nodes, edges, ACC, and degree. Moreover, PFM also altered the bacterial and fungal keystone taxa. In summary, we were able to accurately estimate the influence of PFM on soil quality and microbial ecology, and our results provide valuable information for the sustainable development of dryland agriculture in northern China.