Understanding the processes underlying morphological diversification is a central goal in ecology and evolutionary biology and requires the integration of information about phylogenetic divergence and ecological niche diversity. In the present study, we use geometric morphometrics and comparative methods to investigate morphological diversification in Neotropical spiny rats of the family Echimyidae. Morphological diversification is studied as shape variation in the skull, comprising a structure composed of four distinct units: vault, base, orognathofacial complex, and mandible. We demonstrate association among patterns of variation in shape in different cranial units, levels of phylogenetic divergence, and ecological niche diversification. At the lower level of phylogenetic divergence, there is significant and positive concordance between patterns of phylogenetic divergence and cranial shape variation in all cranial units. This concordance may be attributable to the phylogenetic and shape distances being calculated between species that occupy the same niche. At higher phylogenetic levels of divergence and with ecological niche diversity, there is significant concordance between shape variation in all four cranial units and the ecological niches. In particular, the orognathofacial complex revealed the most significant association between shape variation and ecological niche diversity. This association may be explained by the great functional importance of the orognathofacial complex. © 2009 The Linnean Society of London, Biological Journal of the Linnean Society, 2009, 98, 646–660.