Ever since a bite-size peanut butter cracker made him sputter and cough and break out in hives when he was a toddler, Carter Grodi has been under doctors’ orders to stay away from peanuts. He brought his own cupcake to school birthday parties, learned to read food labels, and turned 15 without ever tasting a Kit Kat, Twix or Three Musketeers bar, all of which may contain traces of peanut because they are made in facilities that process the nuts.

But last year, Carter, now 16, gorged on those candies for the first time without having a reaction. He had just completed a yearlong clinical trial of an oral immunotherapy regimen that aims to reduce children’s sensitivity to peanut allergens by gradually exposing them to peanut protein over the course of six months, starting with minute amounts that are carefully measured and increased incrementally under medical supervision as tolerance develops.

The goal of the treatment is not to cure the allergy or enable children to eat peanut butter sandwiches, but to reduce the risk that an accidental exposure to trace amounts will trigger a life-threatening reaction in someone with a severe allergy, and relieve the fear and anxiety that go along with severe peanut allergies.

The results, announced Sunday at a conference of the American College of Allergy, Asthma & Immunology in Seattle, may lead to approval of what could be the first oral medication that ameliorates reactions in children with severe peanut allergies.

After six months of treatment followed by six months of maintenance therapy, two-thirds of the 372 children who received the treatment were able to ingest 600 milligrams or more of peanut protein — the equivalent of two peanuts — without developing allergic symptoms. By contrast, only 4 percent of the 124 children who had been given a placebo powder were able to consume the same amount of peanut without reacting.

The treatment does not work for everyone. Though only 4.3 percent of children receiving the active drug experienced side effects categorized as severe, compared with less than 1 percent of the children on placebo, 20 percent of the children in the active treatment group withdrew from the study, more than half of them because of adverse events. Fourteen percent of those on active treatment received injections of epinephrine, a drug used in emergencies, including one child who experienced anaphylaxis and required three EpiPen injections. By contrast, only 6.5 percent of those on the placebo received epinephrine.

Demand for the new drug is expected to be high, and though it is made of peanuts, advocates for people with peanut allergies are already expressing concern about how it will be priced and whether it will be covered by insurance.

One in 50 U.S. children is allergic to peanuts. Peanut allergies are believed to cause more deaths from anaphylaxis, an acute allergic reaction that can include constriction of the airways, than any other food allergy. Deaths are rare. Patients do not generally outgrow peanut allergies, so they must be vigilant throughout their lives.

The trial of the drug, called AR101, developed by Aimmune Therapeutics, is to be published Thursday in the New England Journal of Medicine.