Long courses of antibiotics may put babies and toddlers at higher risk of obesity when they grow up, according to US researchers.

Low doses of penicillin early in life can alter natural populations of gut microbes, which in turn may affect metabolism and lead to higher rates of obesity later in life, the scientists said.

The findings emerged from a series of experiments in mice, but build on earlier work that found children who had antibiotics before six months of age were more likely to be overweight as seven-year-olds.

"This is part of a growing body of evidence that antibiotics have a biological cost," said Martin Blaser, a microbiologist who led the study at New York University. "Our study shows that there can be permanent consequences."

"If a kid is very ill, there is no question that they should get antibiotics, but if it's marginal perhaps the doctor should be saying 'let's wait a day or two' before taking another look. Doctors give out antibiotics thinking they won't do any harm, but this provides evidence that they might," Blaser added.

Humans and other animals are home to vast populations of microbes that live on the skin and in the gut. Humans carry around 100 trillion bacteria – meaning our microbes outnumber our human cells by 10 to one. But rather than causing us harm, studies suggest that a healthy "microbiome" is crucial for our wellbeing.

Blaser said that although his studies were in mice, they pointed to a window in early life when changes to the microbiome appeared to have a serious impact on metabolism and weight gain. In mice, the window was the first month of life. If a similar vulnerable period exists in humans, as Blaser suspects, it may be the first six months, the first year, or even three years, he said.

The mouse studies suggest that antibiotics are not directly to blame for weight gain later in life. Instead, the problem arose when antibiotics wiped out some types of gut bacteria but allowed hardier ones to thrive. This change in composition of the "microbiome" had a long-term impact on metabolism that persisted even when the population of gut microbes had returned to normal several weeks later.

"We found that four weeks of antibiotics was enough to perturb the microbiome, and even though it returned to normal after a few weeks, the mice still became fat," Blaser said. Mice that had antibiotics for the first month of life were 25% heavier and had 60% more fat than controls, according to the study published in the journal, Cell.

Disrupting the microbiome seemed to exacerbate the effects of a high-fat diet, too, with animals on antibiotics gaining more weight than others who were not given the drugs. For unknown reasons, males put on more weight than females.

Knocking out four particular species of bacteria with antibiotics seemed to trigger metabolic changes, namely Lactobacillus, Allobaculum, Rikenelleceae, and Candidatus arthromitus. The last of these is found in mice, but does not seem to live in humans.

The New York group has now begun a series of experiments to test whether administering "good microbes" to mice can restore the microbiome quickly enough to prevent metabolic changes and weight gain. Other studies will look at whether more realistic courses of antibiotics that last only three to five days have a similar effect on weight gain.

Paul Cotter at the Teagasc Food Research Centre in Ireland said the findings highlighted the risks of overusing antibiotics. "While these studies were carried out with mice, the insights gained may well be applicable to humans, especially given that previous human studies have established that early life exposure to antibiotics can impact on weight gain later in life," he said.

Naveed Sattar, professor of metabolic medicine at Glasgow University, said that while the results were interesting, they should not alter current clinical practice. "Antibiotics in children or newborns should be given on the basis of clinical needs, whereas the usual advice about lifestyle remains the most important means to tackle obesity," he said.