Abstract The 18O/17O abundance ratio is, in principle, a powerful tool to estimate the relative contributions of massive stars and low- to intermediate-mass stars to the chemical enrichment of galaxies. We present 18O/17O ratios derived from simultaneous observations of C18O and C17O 1-0 toward fifty-one massive star forming regions with the Institut de Radioastronomie Millimétrique (IRAM) 30 meter telescope. Simultaneous observations of HC18O+ 1-0 and HC17O+ 1-0 with the Yebes 40m telescope toward five sources from this sample were also done to test the consistency of 18O/17O ratios derived from different isotopic pairs. From our improved measurements, resulting in smaller errors than previous work in the literature, we obtain a clear trend of increasing 18O/17O ratio with increasing galactocentric distance (DGC), which provides a significant constraint on Galactic chemical evolution (GCE) models. Current GCE models have to be improved in order to explain the observed C18O/C17O 1-0 gradient.