Despite the enormous importance of nectar sources in butterfly ecology, little research has been carried out in determining broad patterns of flower use at the community level. In this paper we report the results of a long-term study (12 years) of the flowers visited by adult butterflies at four sites in northeast Spain encompassing an altitudinal gradient of 1100 m and a rich variety of biotopes. The complete dataset consists of 29 305 recorded flower visits by 100 butterfly and one burnet moth species to 214 different plant species. Our analysis showed firstly that the degree of generalization in flower use is a species trait that remains fairly constant throughout the biotopes and regions occupied by a butterfly species. Related to this pattern, we also found that phylogeny had an important effect on flower use. Of the ecological traits influencing the degree of generalization, the length of the flight period was identified as the most important. Habitat preference was also important, since forest butterflies were more specialized than the butterflies of open habitats. The existence of a link between the degree of generalization in flower use and the degree of larval polyphagy seems more doubtful as we obtained conflicting results that contradict the most plausible biological explanation. Our data provided no support for the hypothesis that rarer species are more specialized than commoner ones, but did seem to confirm a previous finding that body size is not relevant to any explanation of the degree of generalization in adult butterflies.