Species-abundance distributions (SADs) describe the spectrum of commonness and rarity in a community. Beyond the universal observation that most species are rare and only a few common, more-precise description of SAD shape is controversial. Furthermore, the mechanisms behind SADs and how they vary along environmental gradients remain unresolved. We lack a general, non-neutral theory of SADs. Here, we develop a trait-based framework, focusing on a local community coupled to the region by dispersal. The balance of immigration and exclusion determines abundances, which vary over orders-of-magnitude. The local trait-abundance distribution (TAD) reflects a transformation of the regional TAD. The left-tail of the SAD depends on scaling exponents of the exclusion function and the regional species pool. More-complex local dynamics can lead to multimodal TADs and SADs. Connecting SADs with trait-based ecological theory provides a way to generate more-testable hypotheses on the controls over commonness and rarity in communities.