Not sure which factors may be sabotaging your sleep, and which you can keep without losing Zs? López-Yianilos recommends eliminating all of these sleep-eroding habits to start, then slowly reintroduce one-by-one any habits that you feel you can’t live without. By adding back one habit at a time, you’ll be able to determine if that behavior is harming your sleep or not. And remember, proper sleep fitness and hygiene takes training and practice, so don’t worry if you take a misstep every now and then. Similarly, eating a large meal right before bed can affect your gastrointestinal activity and metabolism, in turn impacting your sleep quality. Instead, try to schedule meals to be at least three hours before bedtime, and if you get hungry late at night, stick to a small yet filling snack, like nut butter on crackers, López-Yianilos says. Here are a few of our favorite healthy midnight snack ideas. One caveat: Avoid working out too close to bedtime. This is because exercise raises your body temperature, López-Yianilos explains, and your body temperature should naturally dip as you get ready to sleep.