It’s well known that caffeine negatively affects sleep, but you don’t only need to worry about having a cup of coffee too late in the day—you should also be checking the contents of any medication you’re taking close to bedtime. Many common OTC meds contain caffeine, from Excedrin to Midol, so check the ingredients to make sure that pill you pop before bed won’t keep you up. And for another type of drug that could cause you trouble, check out If You Take This Medication, U.S. Officials Have a New Warning for You. While it may seem like a strange addition to medication, caffeine is commonly found in headache and migraine medications. “During a headache, blood vessels swell, tighten or go through other changes, causing an increase in blood flow around the brain. This increases blood flow pressures surrounding nerves, which send pain messages to the brain. This brings on the headache,” explain the experts at the Mayo Clinic. “Caffeine has vasoconstrictive properties, meaning that blood vessels narrow to restrict blood flow, thereby alleviating the pain.” And for more useful health information delivered straight to your inbox, sign up for our daily newsletter. A Nov. 2013 study from The Journal of Clinical Sleep Medicine found that “caffeine taken six hours before bedtime has important disruptive effects on sleep.” So, if you tend to go to bed around 10 p.m., don’t take any OTC medications with caffeine past 4 p.m. unless you want to be up all night. The Sleep Foundation notes that some people may need an even longer period without caffeine before bed, so keep track of how it affects your sleep, adjusting the length of time between the OTC meds and bedtime as needed. To make sure how you’re medicating isn’t a problem, beware that If You’re Taking This OTC Medicine More Than Twice a Week, See a Doctor. If you need to take a pain reliever before bed, it’s best to seek out one that doesn’t contain caffeine. Midol sells a caffeine-free pill, and Excedrin has a special nighttime formula that is also devoid of caffeine.ae0fcc31ae342fd3a1346ebb1f342fcb Additionally, you can stick to other common OTC pain relievers such as Advil, Tylenol, Motrin, and Aleve. And to learn which OTC medication is best for your specific ailment, check out This Is When You Should Take Tylenol Instead of Advil, Doctors Say.