ABSTRACT: Laboratory experiments have shown that the UV photo-irradiation of low-temperature ices of astrophysical interest leads to the formation of organic molecules, including molecules important for biology such as amino acids, quinones, and amphiphiles. When pyrimidine is introduced into these ices, the products of irradiation include the nucleobases uracil, cytosine, and thymine, the informational sub-units of DNA and RNA, as well as some of their isomers. The formation of these compounds, which has been studied both experimentally and theoretically, requires a succession of additions of OH, NH?, and CH?groups to pyrimidine. Results show that H?O ice plays key roles in the formation of the nucleobases, as an oxidant, as a matrix in which reactions can take place, and as a catalyst that assists proton abstraction from intermediate compounds. As H?O is also the most abundant icy component in most cold astrophysical environments, it probably plays the same roles in space in the formation of biologically relevant compounds. Results also show that although the formation of uracil and cytosine from pyrimidine in ices is fairly straightforward, the formation of thymine is not. This is mostly due to the fact that methylation is a limiting step for its formation, particularly in H?O-rich ices, where methylation must compete with oxidation. The relative inefficiency of the abiotic formation of thymine to that of uracil and cytosine, together with the fact that thymine has not been detected in meteorites, are not inconsistent with the RNA world hypothesis. Indeed, a lack of abiotically produced thymine delivered to the early Earth may have forced the choice for an RNA world, in which only uracil and cytosine are needed, but not thymine.