Anyone who has tried to eat a more healthy diet lately knows it costs more to eat all those fresh fruits and vegetables. But a new study by the University of Washington has found that it’s getting more expensive all the time — and may even be out of reach for some.

The first-of-its-kind study by UW researchers found that between 2004 and 2006, the costs of some healthy foods went up nearly 20 percent at major Seattle supermarkets. But over the same period, the cost of some junk foods dropped.

“Healthy foods are gradually slipping out of reach for all but the affluent consumers,” said Adam Drewnowski, director of the University of Washington Center for Public Health and Nutrition and an author of the study.

“Foods we thought of as being everyday, healthy, nutritious foods are becoming luxury items.”

Most Read Stories

The study tracked changes in prices over time and sorted by food quality. It compared the cost of more than 370 types of food purchased at three Seattle supermarket chains: QFC, Albertsons and Safeway.

The researchers compared the cost of food that is low in calories by weight — generally fresh fruits and vegetables — with the costs of higher-calorie foods, such as candy, pastries and snacks that are high in refined grains, sugars and fat.

The 20 percent increase in cost of the healthy foods, such as fresh fruits and vegetables, was way ahead of the overall cost increase of all the food combined, which was 5 percent.

The study, by Drewnowski, and Pablo Monsivais, a research fellow at the center, was published in the December issue of the Journal of the American Dietetic Association.

The findings were discouraging to experts who have long been concerned that poor people lack access to healthy food and face higher rates of obesity and related health problems, such as diabetes and heart disease.

“It’s a justice issue,” said David Bobanick of the Access to Healthy Foods Coalition, a Wenatchee-based nonprofit. “For people on limited incomes, this is so much more than an annoyance. You weigh the decision, ‘Do I fill my child’s empty stomach so they don’t feel the pang of hunger with what I can afford? Or do I try to feed them nutritious food?’ “

The study has its limitations, the researchers are quick to note. For example, the pricing didn’t take into account such things as coupons, store chains’ loyalty cards that grant reduced prices or sale offers. And the researchers stuck to the chain stores, so they didn’t weigh options such as farmers markets, where fresh food can cost less.

But they also came away with some advice for the shopper on a budget.

One big one: Go for frozen and canned vegetables and soups, which often have the same nutritional value at a lower cost.

“Fresh is a middle-class obsession,” Drewnowski said.

For researcher Monsivais, the findings were “kind of a shocker” because they contradict a popular assumption that food is cheap in America.

But that notion “doesn’t tell you anything for those of us trying to eat healthy,” he said.