Objective To evaluate the sustainability of the dietary patterns, according to their effects on health and environment and their affordability. Design Prospective, ongoing cohort study of university graduates. Settings The Spanish SUN project (Seguimiento Universidad de Navarra, University of Navarra Follow-up), starting from 1999. Participants A total of 18 429 participants. Methods Information from participants is collected every 2 years by validated questionnaires. We assessed three dietary patterns (the Mediterranean, the Western and the Provegetarian dietary patterns). The rate advancement period (RAP) was used to assess the healthiness of each pattern (considering the composite endpoint of all-cause mortality, cardiovascular disease, breast cancer or type 2 diabetes). We also assessed environmental footprints and monetary costs of each dietary pattern. Results After a median follow-up of 10.1 years, we identified 469 incident cases of the composite endpoint. The Mediterranean dietary pattern exhibited the best RAP (3.10 years gained [95% CI 4.35 to 1.85] for the highest vs the lowest quartile), while the Western pattern was the unhealthiest pattern (1.33 years lost when comparing extreme quartiles). In a scale between 4 and 16 of harmful environmental effects (the lower, the more environmentally friendly), the Provegetarian pattern scored best (8.82 [95% CI 8.75 to 8.88] when comparing extreme quartiles), whereas the Western pattern was the most detrimental pattern (10.80 [95% CI 10.72 to 10.87]). Regarding monetary costs, the Western pattern was the most affordable pattern ((sic)5.87/day [95% CI 5.82 to 5.93], for the upper quartile), while the Mediterranean pattern was the most expensive pattern ((sic)7.52/day [95% CI 7.47 to 7.56]). The Mediterranean dietary pattern was the most overall sustainable option, closely followed by the Provegetarian pattern. The least overall sustainable pattern was the Western dietary pattern. Conclusion Following plant-based diets, like the Mediterranean or Provegetarian dietary patterns, could be a good option in order to achieve an overall sustainable diet.