Want to sleep better tonight? Consider eating plenty of nutrient-dense plant foods like fruits, vegetables, whole grains, beans, nuts and olive oil.

That’s one of the major takeaways from a new study published in the journal Nature Health that examined how the foods people ate during the day impacted how they slept at night. In the study, researchers closely tracked thousands of participants for years — analyzing their diets and scrutinizing many aspects of their health and sleep behaviors.