Stop your gadgets from keeping you awake at night

Staying up late with your tablet or phone can rob you of a good night's sleep. Fight back with these tips.

Josh Miller/CNET

Have a hard time falling asleep? It might be time to stop falling asleep with your gadgets. Study after study after study has shown that light given off by electronics affects our sleep health.

The consensus is that the blue light that LED screens give off can slow or halt the production of melatonin, the hormone that signals our brain that it's time for bed.

Without melatonin, we stay awake and alert, keeping us up later than intended. If you really want to get deep on this topic, read up on retinal ganglion cells, the sensors in our eyes that may be to blame for this phenomenon.

The simplest solution is to shy away from your phone or tablet before bed. But what if you can't give up late-night Netflix sessions on your tablet, or thumbing through Instagram on your phone? Here's help to stave off some of the negative effects of your screen addiction.

Apps for your weary eyes

With iOS 9.3, Apple finally added a built-in way to battle the dreaded blue light by using a warm orange-red filter that changes the color temperature of your screen.

Turn on Night Shift in the settings app of your iPhone or iPad running iOS 9.3 and there you can adjust the hue of the screen. You can even schedule Night Shift to run during certain hours of the night and turn off automatically.

Foryour computer, tryFlux, which adapts your device's screen to the time of day, changing the hue of your screen when the sun sets. The subtle orange-red filter is easier on the eyes and automatically disappears when the sun rises again in the morning. Once you set up Flux, it runs in the background and adjusts based on your location and the time of year. The app is available for free for Windows, Mac and Linux and it's easy to install.

Twilight adjusts your screen temperature to block out blue light. Screenshot by Sarah Mitroff/CNET

Also free, Twilight works a lot like Flux, but it's built for Android devices. You get a bit more control with the app over the hue and intensity, using sliders in the app to adjust the color from deep red to pale yellow. You can opt for Twilight to stay on at all times, set specific times for it to run or let it work automatically, by coming on and shutting off with the setting and rising of the sun.

Hardware help

Software isn't the only tool you can use to fight the dreaded blue light. There are a few external products promising to help too.

Though they are hardly fashionable, some research suggests wearing glasses with amber- or orange-colored lenses can block out blue light. These are usually sold as safety goggles and you can pick them up at most hardware stores or online for a couple bucks. They have an added benefit of blocking out blue light from your entire environment, including house lights and your TV.

You can also opt for a screen protector that combats blue light from your screen at all times. There are several options out there, and the highest-rated ones are from Tech Armor for the iPad and iPhone. These work just like other screen protectors, though reviews are mixed on how well they block out blue light.

Shut off and go to sleep

Despite all these efforts, some studies suggest that simply staring at a screen before bed, whether it's giving off blue light or not, can keep you awake longer. Bright light in our environment can signal our brains to stay alert and we get a direct dose of it by looking at a phone or computer. Do yourself a favor and put down your tablet or phone at least 1 hour before bed -- it could help you get a more restful night of sleep.

Featured Video