Federal health officials on Thursday issued new food allergy guidelines that could help reduce peanut allergies among children — and that, contrary to past guidance, call for parents to give babies foods containing peanuts as early as 4 to 6 months of age.

The new guidelines from the National Institute of Allergy and Infectious Diseases, part of the National Institutes of Health, reflect an improved scientific understanding of the best ways to prevent the development of allergies.

“There is this magic window of opportunity, where you can introduce peanut-containing foods,” said Dr. David Stukus, a pediatric allergist in Ohio and a coauthor of the new guidelines.

“Our immune system undergoes dramatic development and maturation during the first years of life,” he added. “We introduce peanut-containing foods early, the immune system can get used to it.”

The guidelines vary based on an infant’s perceived risk.

The agency recommends the introduction of peanut-containing foods as early as 4 to 6 months for infants at high risk of developing a peanut allergy — those who have severe eczema or an egg allergy — though those infants should first be seen by an allergy specialist.

Children who face a moderate risk of developing a peanut allergy — those with mild to moderate eczema — should have foods with peanuts starting around 6 months of age. Those children need not be evaluated by a specialist.

In May, government experts in Australia issued similar guidelines. As in the US, Australia’s medical community once thought that less exposure to allergens was better.

“We ate up the notion that delayed introduction of more allergenic foods in early childhood would help overcome the increasing rates of food allergy,” University of Western Australia researchers wrote in a December study. “Then we promptly spat it out again [as advice] despite limited evidence.”

The thinking is changing fast, said Debbie Palmer, an allergy and immunology researcher and a coauthor of the Australian study.

“Now our guidelines recommend that all infants should be given allergenic foods including peanut butter, cooked egg, dairy, and wheat in the first year of life,” she said. “This includes infants at high risk of allergy.”

The US guidelines take a slightly more cautious approach, in that they explain how to proceed with the introduction of peanuts based on an infant’s risk.

“For a small group there is a need for them to be evaluated first,” said Stukus. “But for the vast majority of infants, it’s going to be safe to introduce the foods at home.”

The guidelines offer several suggestions on foods containing peanuts and caution that they should not be given to infants who are not yet eating solid foods.

Republished with permission from STAT. This article originally appeared on January 5, 2017