"Prolonged breastfeeding was associated with significant reductions in both colds and ear infections, which is a common complication of the cold," said lead researcher Tasnee Chonmaitree, professor at University of Texas in US.
"It is likely that medical interventions in the past few decades, such as the use of pneumonia and flu vaccines and decreased smoking helped reduce ear infection incidences," he said.
Ear infections in young infants who are under six months old are at an increased risk of having the infection recurrently later in life.
The findings, published in the journal Pediatrics, revealed that the rates of ear infection dropped from 18 to 6 percent in three month olds, from 39 to 23 percent in six month old babies and from 62 to 46 percent in one year old infants.
For the study, 367 babies less than one month old were investigated from October 2008 to March 2014, till their first birthday.
The team collected nose and throat mucus samples throughout the study to seek out and identify infections and gathered information on family history of ear infections, cigarette smoke exposure and breast versus formula feeding.
Parents notified whenever their baby showed any signs of an ear infection or upper respiratory infection, which is the common cold.
"We clearly showed that frequent upper respiratory infections, carriage of bacteria in the nose, and lack of breastfeeding are major risk factors for ear infections," said Chonmaitree.
Acute otitis media, or an ear infection, is one of the most common childhood infections, the leading cause of visits to doctors by children and the most common reason children take antibiotics or undergo surgery.