The pervasive glow of electronic devices may be an impediment to a good night’s sleep.

That’s particularly noticeable now, when families are adjusting to early wake-up times for school. Teenagers can find it especially hard to get started in the morning. As lamps switch off in teens’ bedrooms across America, the lights from their computer screens, smartphones and tablets often stay on throughout the night. These devices emit light of all colours, but it’s the blues in particular that pose a danger to sleep. Blue light is especially good at preventing the release of melatonin, a hormone associated with night-time.

For nocturnal animals, it spurs activity. For daytime species such as humans, melatonin signals that it’s time to sleep.

Ordinarily, the pineal gland, a pea-size organ in the brain, begins to release melatonin a couple of hours before your regular bedtime. The hormone is no sleeping pill, but it does reduce alertness and make sleep more inviting.

However, light — particularly of the blue variety — can keep the pineal gland from releasing melatonin, thus warding off sleepiness. You don’t have to be staring directly at a television or computer screen: If enough blue light hits the eye, the gland can stop releasing melatonin. So easing into bed with a tablet or a laptop makes it harder to take a long snooze, especially for sleep-deprived teenagers who are more vulnerable to the effects of light than adults.

During adolescence, the circadian rhythm shifts, and teens feel more awake later at night. Switching on a TV show or video game just before bedtime will push off sleepiness even later even if they have to be up by 6am to get to school on time.

The result? Drowsy students struggling to stay awake, despite the caffeinated drinks many kids now consume.

“Teenagers have all the same risks of light exposure, but they are systematically sleep-deprived because of how society works against their natural clocks,” said sleep researcher Steven Lockley of Harvard Medical School. “Asking a teenager to get up at 7am is like asking me to get up at 4am.”

In a 2014 poll, the National Sleep Foundation, an advocacy organisation, polled parents, asking them to estimate their children’s sleep. More than half said their 15-to-17-year-olds routinely get seven hours or fewer hours of sleep. (The recommended amount for teens is 8 1/2 to 10 hours.) In addition, 68 per cent of these teens were also said to keep an electronic device on all night — a television, computer, video game or something similar.

Based on what parents reported, sleep quality was better among children age 6 to 17 who always turned their devices off: 45 per cent of them were described as having excellent sleep quality vs. 25 per cent of those who sometimes left devices on.

“It is known that teenagers have trouble falling asleep early, and every teenager goes through that,” said light researcher Mariana Figueiro of the Rensselaer Polytechnic Institute in Troy, N.Y.

Figueiro investigates how light affects human health, and her recent research focused on finding out which electronics emit blue light intense enough to affect sleep. When comparing melatonin levels of adults and teenagers looking at computer screens, she was astonished by the younger group’s light sensitivity. Even when exposed to just one-tenth as much light as adults were, the teens actually suppressed more melatonin than the older people.

In another experiment, she had adults use iPads at full brightness for two hours and measured their melatonin levels with saliva samples. One hour of use didn’t significantly curtail melatonin release, but two hours’ did.

So although teenagers may be particularly susceptible, we all should be aware that artificial light can affect our circadian rhythms.

“The premise to remember is [that] all light after dusk is unnatural,” Lockley said. “All of us push our sleep later than we actually would if we didn’t have electric light.”

A study from 2013 found that people who spent a week camping in the Rocky Mountains, exposed to only natural light and no electronic devices, had their circadian clocks synchronised with the rise and fall of the sun. Although there were only eight campers, they all reacted in the same way, whether they considered themselves early birds or night owls.

To counteract the effects of tablets’ blue light, Figueiro and Lockley recommend a free app, F.lux, that automatically warms up the colours on your various screens — more reds and yellows — at sunset and returns them to normal at sunrise.

“The amount of light you need [in order] to see is lower than the amount of light you need to affect your melatonin,” Figueiro said, which means that light-emitting screens can be used at night without disrupting sleep cycles if you put some distance between your eyes and the device. In other words, place the tablet farther away from your face than usual, or watch TV instead. Also, turning the brightness setting down on laptops, tablets and phones should help.