The healthiest meals children eat during the day come from school cafeterias, a new study found.
CNN  — 

School food is often given a bad rap, but a new study found it can be the healthiest meal children eat in a day.

Researchers analyzed the diets of over 21,000 children and 40,000 adults between 2003 and 2018 and found that the percentage of “poor nutritional quality food consumed from schools” declined from 55% to 24% over the 15-year period, according to a study published Monday in JAMA Network Open.

The decrease mainly occurred after 2010, which is when the Healthy, Hunger-Free Kids Act was passed, said study author Dr. Dariush Mozaffarian, dean of Tufts Friedman School of Nutrition Science and Policy and professor of medicine at Tufts School of Medicine.

Nutrition quality was measured using multiple scales including the United States Department of Agriculture’s Healthy Eating Index, which scores a person’s diet using nine adequacy components (total fruit, whole fruit, total vegetables, greens or beans, whole grains, dairy, total protein foods, seafood or plant protein, and fatty acids) and four moderation components (refined grains, sodium, added sugars and saturated fat).

The act established new nutrition standards for meals in schools to ensure children have access to healthy meals, according to the USDA. Some of the standards include offering students both fruits and vegetables every day and limiting the number of calories served based on children’s ages.

“It shows you how a single policy passed by Congress can dramatically improve the nutrition of millions of children,” Mozaffarian said.

In the results, researchers also found that the increase in healthy eating in schools equally impacted all ethnicities included in the study.

The majority of calories are from the grocery store

However, Mozaffarian noted, only 9% of the calories children eat come from schools. For adults and children, about two-thirds of the food consumed come from the grocery store.

Over the 15-year study, the amount of unhealthy food consumed from the grocery store by children decreased from 53% to 45%. For adults, the drop was from 40% to 32%.

Mozaffarian said he sees grocery stores as the “greatest opportunity for improving diet quality” because the majority of calories people consume are purchased at these establishments.

One solution would be true cost accounting, he said, which is where food is priced based off its societal costs, including its cost on people’s health.

“Food that actually makes people healthier should cost less and be more readily available,” Mozaffarian said. “Foods that are making people sick and also hurting the environment should be more expensive.”

When parents don’t bring processed foods into the house, it’s one less opportunity for children to eat it, said Marion Nestle, Paulette Goddard professor emerita for nutrition, food studies and public health at New York University, who was not involved in the study.

Another strategy to decrease the amount of unhealthy food children are consuming from the grocery store is to stop companies from advertising unhealthy food to children, Nestle said.

She said children have been brainwashed into believing they’re supposed to be eating “kids’ food” like cereals and fast foods marketed to children. But in reality, Nestle said, there is no such thing as “kids’ food.”

Nestle continued, “Kids should be eating exactly what their parents do. And their parents should be eating healthfully to the extent that they can, so there’s no need to buy special foods for kids.”

Get CNN Health's weekly newsletter

Sign up here to get The Results Are In with Dr. Sanjay Gupta every Tuesday from the CNN Health team.

In addition, she recommended grocery stores position healthier foods in locations that are prime real estate, like end aisles and shelves that are at eye level for adults and children.

“There’s no reason why kids can’t appreciate healthy foods,” Nestle said, noting that nutritious food at school and home can be delicious.