The microbial community interacts with the environment and the health and immune function of its host both directly and indirectly. However, very few studies about microbial communities have considered habitat and external environmental variables. This study examined environmental influences on the microbial community of Pachygrontha antennata, which is found in various habitats (e.g., urban, forested, and agricultural areas). The results demonstrated that the composition of the microbial community differed according to land use, while the bacterial diversity did not. In urban areas with high environmental heterogeneity, microbial community diversity tended to be high. Furthermore, bacteria in forests and agricultural areas (e.g., Paraburkholderia, Burkholderia) have been found to be highly correlated with habitat variables. Therefore, we suggest that habitat variables should be considered in future symbiotic studies.