Species as diverse as humans and ants are among the most abundant organisms on Earth, partly because of their ability to form cooperative societies1-3. Yet, animals form groups for many reasons4,5, and how these differences affect their ‘social conquests’2 remains unknown. Here we use a theoretical model to demonstrate that the different fitness benefits that animals receive by forming groups4,6 depend on the quality of their environment, which in turn impacts their ecological dominance and resilience to global change. Our model predicts species that group because of environmental hardships will have wider ecological niches, larger geographic ranges, and higher abundances than non-social species, whereas those that group because of intraspecific resource competition will not. As predicted, an analysis of >1500 avian species finds that cooperative breeders occurring in harsh and fluctuating environments have larger ranges and higher abundances than non-cooperative breeders, whereas cooperative breeders occurring in benign and stable environments do not. These results are consistent with our model predictions showing that species cooperating in harsh or fluctuating environments will be less vulnerable to climate change than non-social species and those cooperating against intra-specific competitors in benign or stable environments. Ultimately, by combining macroecological and sociobiological perspectives, our study helps understand and predict the past, present, and future state of social species, including our own.