Megachilidae is one of the United States’ most diverse bee families, with 667 described species in 19 genera. Unlike other bee families, which are primarily ground nesters, most megachilid bees require biotic cavities for nesting (i.e., wood, pithy stems, etc.). For this group, the availability of woody-plant species may be as important as nectar/pollen resources in maintaining populations. We studied Megachilidae biodiversity in the continental United States. We confirmed that the highest species richness of Megachilidae was in the southwestern United States. We examined the relationship between species richness and climate, land cover, tree species richness, and flowering plant diversity. When examining environmental predictors across the conterminous United States, we found that forested habitats, but not tree diversity, strongly predicted Megachilidae richness. Additionally, Megachilidae richness was highest in areas with high temperature and low precipitation, however this was not linearly correlated and strongly positively correlated with flowering plant diversity. Our research suggests that the availability of nesting substrate (forested habitats), and not only flowering plants, is particularly important for these cavity-nesting species. Since trees and forested areas are particularly susceptible to climate change, including effects of drought, fire, and infestations, nesting substrates could become a potential limiting resource for Megachilidae populations.