Although extrafloral nectar (EFN) is a key food resource for arboreal ants, its role in structuring ground-nesting ant communities has received little attention, despite these ants also being frequent EFN-attendants. We investigated the role of EFN as a driver of the spatial structure of ground-nesting ant communities occurring in dry forest in north-eastern Brazil. We examined the effects on this relationship of two global drivers of biodiversity decline, chronic anthropogenic disturbance and climate change (through decreasing rainfall). We mapped EFN-producing plants and ant nests in 20 plots distributed along independent gradients of disturbance and rainfall. We categorized ant species into three types according to their dependence on EFN: heavy users, occasional users and non-users. We found a strong relationship between ant dependence on EFN and nest proximity to EFN-producing plants: heavy-users (mean distance 1.1 m) nested closer to EFN-producing plants than did occasional users (1.7 m), which in turn nested closer to EFN-producing plants than did non-users (2.3 m). Neither disturbance nor rainfall affected the proximity of heavy-user nests to EFN-producing plants. Our study shows for the first time that EFN is a key driver of the spatial structure of entire communities of ground-nesting ants.