Habitat degradation and climate change are thought to be altering the distributions and abundances of animals and plants throughout the world, but their combined impacts have not been assessed for any species assemblage. Here we evaluated changes in the distribution sizes and abundances of 46 species of butterflies that approach their northern climatic range margins in Britain-where changes in climate and habitat are opposing forces. These insects might be expected to have responded positively to climate warming over the past 30 years, yet three-quarters of them declined: negative responses to habitat loss have outweighed positive responses to climate warming. Half of the species that were mobile and habitat generalists increased their distribution sites over this period (consistent with a climate explanation), whereas the other generalists and 89% of the habitat specialists declined in distribution size (consistent with habitat limitation). Changes in population abundances closely matched changes in distributions. The dual forces of habitat modification and climate change are likely to cause specialists to decline, leaving biological communities with reduced numbers of species and dominated by mobile and widespread habitat generalists.