The nationally representative study involved nearly 600 children with attention deficit hyperactivity disorder followed from kindergarten through fifth grade.
Children's scores on several standardized math and reading tests taken during those years were examined. Compared with unmedicated kids, average scores for medicated children were almost three points higher in math and more than five points higher in reading. The difference amounts to about three months ahead in reading and two months in math, the researchers said.
Both groups had lower scores on average than a separate group of children without ADHD. The researchers acknowledged that gap but said the benefits for medicated youngsters were still notable.
"We're not trying to say in this study that medication is the only answer," but the results suggest benefits that parents, educators and policy-makers shouldn't ignore, said Richard Scheffler, the lead author and professor at the University of California at Berkeley's School of Public Health.
The researchers agreed that other treatment ADHD children often receive - including behavior therapy and tutoring - can help, but the study didn't look at those measures.
Most ADHD drug users in the study were on stimulants; the study didn't identify which ones.
About 4 million U.S. children have been diagnosed with ADHD. About half of them take prescription medication - often powerful stimulants like Ritalin - to control the extreme fidgetiness and impulsive behavior that characterize the condition.
Often, kids with ADHD struggle in class and get lower grades than their classmates. They also have higher dropout rates.
American Academy of Pediatrics guidelines say stimulant drugs are effective but that behavior techniques should also be used.
Teachers often advocate medication because it can calm disruptive behavior. But it's a contentious issue for many parents, worried about putting their kids on drugs that can have side-effects including decreased appetite, weight loss and insomnia.
Previous evidence suggests teachers give higher grades to ADHD kids on medication, but the study authors said that might simply mean teachers prefer them because they're better behaved than unmedicated children.
They said theirs is the largest, longest-duration study based on objective standardized academic tests suggesting that medicated kids may be better learners, too.
Psychiatrist Dr. Bennett Leventhal, who was not involved in the study, called the results impressive.
"It doesn't mean that every child with ADHD should be taking medication," but previous studies have suggested that most affected kids can benefit, said Leventhal, a University of Illinois-Chicago psychiatry professor.
The study appears in the May issue of Pediatrics, released Monday. A federal grant paid for the research; the authors said they have no financial ties to ADHD drugmakers.
Dr. Louis Kraus, a psychiatrist with Chicago's Rush University Medical Center, said he worries the study will make parents turn to medication without considering other options. Behavioral treatment generally should be tried first, Kraus said.
Blake Taylor, a 19-year-old Berkeley sophomore who's been on ADHD medication since age 5, said the results aren't surprising.
Medication "doesn't make me smarter," he said, "it allows me to focus, to be more organized."
He recalled doing poorly on a high school exam that he'd studied hard for, but he hadn't taken his ADHD medication that day. He said his mind kept wandering, thinking about war posters on the classroom walls and noise from children playing outside.
Taylor said when he was younger he sometimes skipped his medicine because, like many teens, "I didn't want to be different from my other classmates." Taking his medication was a reminder, he said.
His other treatments have included counseling and organizational tutoring; Taylor said daily cardio and weightlifting workouts help, too, using up excess energy.