Habitat shifts from land to water have occurred independently in several mammal lineages. However, because we do not know completely about the relationship between skeletal morphology and function, both reliable life reconstructions of each extinct taxon and the timing of those shifts in locomotor strategies are yet to be fully understood. We estimated the strengths of rib cages against vertical compression in 26 extant and four extinct mammal specimens including cetartiodactyls, paenungulates, and carnivorans, representing 11 terrestrial, six semi-aquatic, and nine obligate aquatic taxa. Our analyses of extant taxa showed that strengths were high among terrestrial/semi-aquatic mammals, whose rib cages are subjected to vertical compression during the support on land, whereas strengths were low among obligate aquatic mammals, whose rib cages are not subjected to antigravity force in the water. We therefore propose rib strength as a new index to estimate the ability of an animal to be supported on land while being supported by either the forelimbs or thoracic region. According to our analyses of extinct taxa, this ability to be supported on land was rejected for a basal cetacean (Cetartiodactyla: Ambulocetus) and two desmostylians (Paenungulata: Paleoparadoxia and Neoparadoxia). However, this ability was not rejected for one desmostylian species (Desmostylus). Further study of the ribs of extant/extinct semi-aquatic taxa may help in understanding the ecological shifts in these groups.