Watching TV and spending time online could rob teenagers of success in their GCSE exams, research has shown.
A study that tracked the progress of 845 students between the ages of 14 and 16 found that every extra hour they devoted to TV viewing, internet use, or playing computer games reduced their scores by the equivalent of two grades.
While reading and homework improved performance, it could not make up for long periods of time in front of a screen.
The scientists stress that what they found was an association, not proof of a causal link. But they have ruled out the influence of poverty or affluence - the students, who attended 18 different schools in Cambridgeshire and Suffolk, came from a diverse range of social backgrounds.
Lead researcher Dr Kirsten Corder, from Cambridge University, said: "Television, computer games and internet use were all harmful to academic performance, but TV viewing was the most detrimental.
"We can cautiously infer that increased screen time may lead to poorer academic performance for GCSEs.
"I certainly wouldn't recommend banning television. But if teenagers or parents are concerned about GCSE results, one thing might be to look at the amount of TV viewing that they're doing and maybe just try to be sensible about it."
The research was part of a large study looking at different factors affecting the mental health, well-being and academic achievement of teenagers as they make the journey to adulthood.
Between 2005 and 2007, the scientists measured activity levels of the participants using heart rate and movement sensors attached to their bodies. They also questioned the students about how much time they spent in front of TV or computer screens, doing homework, or reading for pleasure.
GCSE performance was assessed at 16, by adding together all the points students obtained across different subjects.
Points are awarded for different grades on a descending scale. An A star, for instance, earns 58 points and an A, 52.
Every extra hour spent watching TV or online was associated with 9.3 fewer GCSE points overall at age 16 - equivalent to the difference between two grades, for instance dropping from a B to a D.
According to the communications regulator Ofcom, the UK's 11 to 15-year-olds spend three hours a day on average in front of TVs or computer screens.
For participants in the study, the typical amount of screen time per day was four hours. Every extra hour was associated with 9.3 fewer GCSE points, and two extra hours was associated with 18 fewer points.
Teenagers who spent an extra hour doing homework or reading achieved 23 more GCSE points on average than their peers. But only 58 fell into this category, and the scientists said they may represent pupils forced to work harder because they were struggling at school.
Dr Corder added: "Even if you do sufficient homework, television viewing would still potentially lower your GCSE results."
The results are published in the International Journal of Behavioral Nutrition and Physical Activity.
They also showed that levels of physical exercise and sport had no impact on GCSEs.
This was important because there was a wide misconception that being good at sport detracted from academic achievement, said the authors.
Dr Esther van Sluijs, another member of the Cambridge team, said: "We believe that programmes aimed at reducing screen time could have important benefits for teenager's exam grades, as well as their health.
"It is also encouraging that our results show that greater physical activity does not negatively affect exam results. As physical activity has many other benefits, efforts to promote physical activity throughout the day should still be a public health priority."