Squalene is mostly associated with the biosynthesis of polycyclic triterpenes. Although there have been suggestions that squalene could be involved in the biosynthesis of carotenoids, functionally and evolutionarily related to polycyclic triterpenes, evidence of this 'squalene route' in nature was lacking. We demonstrate that planctomycetes synthesize C30 carotenoids via squalene and that this 'squalene route' is widely distributed in Bacteria. We also investigated the functional roles of hopanoids and carotenoids in Planctomycetes and show that their protective functions under stress conditions are complementary. Our evolutionary analyses suggest that the C30 carotenoid biosynthetic pathway is the most ancestral, with a potential origin in Firmicutes or Planctomycetes . In addition, we propose an evolutionary scenario to explain the diversification of the different carotenoid and squalene pathways. Together, these results improve the evolutionary contextualization of these molecules. Likewise, the widespread occurrence of the squalene route in bacteria increases the functional repertoire of squalene.