One of the most important physiological challenges animals had to overcome during terrestrialization (i.e., the transition from sea to land) is water loss, which alters their osmotic and hydric homeostasis. Aquaporins are a superfamily of membrane water transporters heavily involved in osmoregulatory processes. Their diversity and evolutionary dynamics in most animal lineages remain unknown, hampering our understanding of their role in marine-terrestrial transitions. Here, we interrogated aquaporin gene repertoire evolution across the main terrestrial animal lineages. We annotated aquaporin-coding genes in genomic data from 458 species from 7 animal phyla where terrestrialization episodes occurred. We then explored aquaporin gene evolutionary dynamics to assess differences between terrestrial and aquatic species through phylogenomics and phylogenetic comparative methods. Our results revealed parallel aquaporin-coding gene duplications in aquaporins transporting water, glycerol and ammonia in the transition from marine to non-marine environments (e.g., brackish, freshwater and terrestrial), rather than from aquatic to terrestrial ones, with some notable duplications in ancient lineages. Contrarily, we also recovered a significantly lower number of oxygen peroxide-transporting aquaporin-coding genes in terrestrial arthropods, suggesting that more efficient oxygen homeostasis in land arthropods might be linked to a reduction in this type of aquaporins. Our results thus indicate that aquaporin-coding gene duplication and loss might have been one of the key steps towards the evolution of osmoregulation across animals, facilitating the "out of the sea" transition and ultimately the colonisation of land.