Eating a diet that is high in fat and sugar may reduce sleep quality by messing with the brain’s electrical activity during deep sleep. When we go to sleep, our brain’s electrical activity slows down.