As all drivers know, a foggy windshield isn’t just a nuisance—the low visibility can also make driving more dangerous.

The issue crops up often during winter, when it’s significantly warmer inside the car than it is outside. Basically, hot air can hold much more moisture than cold air; so when the saturated air from the car’s heated interior collides with the cold windows, some of that moisture turns into condensation. Since keeping the temperatures even by never turning your heat on isn’t really an option, former NASA engineer Mark Rober devised a series of experiments to determine how to clear the fog as quickly as possible.

In the video below, Rober explains that the general goal is to swap out the humid hot air with dry air that can absorb moisture. Outdoor air is dry, but it’s also cold—so when you let it enter your car, you need to heat it up. In other words, crack your windows (weather permitting), keep the “air circulation” button turned off, and crank the heat. You should also crank the air conditioning, which will help take more moisture out of the air.

Rober has a couple tips for keeping your windows fog-free in the first place, too. Cat litter is extremely absorbent, so putting a litter-filled sock on your dashboard supposedly helps suck up some excess moisture before it condenses on your windshield. And while anti-fog spray definitely does the trick, Rober found that wiping your windshield with shaving cream is just as effective.

As Lifehacker points out, the video’s title slide suggests that Rober will be discussing defrosting, though he only covers defogging. If you're still looking for defrosting advice, here’s a handy hack.

[h/t Lifehacker]