You know that an evening coffee can leave you tossing and turning in the wee hours. But other foods hurt sleep, too….

Premium ice cream. Brace yourself for a restless night if you indulge in Häagen-Dazs or Ben & Jerry’s late at night. The richness of these wonderful treats comes mainly from fat—16 to 17 grams of fat in half a cup of vanilla, and who eats just half a cup?

Your body digests fat more slowly than it digests proteins or carbohydrates. When you eat a high-fat food within an hour or two of bedtime, your digestion will still be “active” when you lie down—and that can disturb sleep.

Also, the combination of stomach acid, stomach contractions and a horizontal position increases the risk for reflux, the upsurge of digestive juices into the esophagus that causes heartburn—which can disturb sleep.

Chocolate. Some types of chocolate can jolt you awake almost as much as a cup of coffee. Dark chocolate, in particular, has shocking amounts of caffeine. Example: Half a bar of Dagoba Eclipse Extra Dark has 41 milligrams of caffeine, close to what you’d get in a shot of mild espresso.

Chocolate also contains theobromine, another stimulant, which is never a good choice near bedtime.

Beans. Beans are one of the healthiest foods. But a helping or two of beans—or broccoli, cauliflower, cabbage or other gas-producing foods—close to bedtime can make your night, well, a little noisier than usual. No one sleeps well when suffering from gas pains. You can reduce the “backtalk” by drinking a mug of chamomile or peppermint tea at bedtime. They’re carminative herbs that aid digestion and help prevent gas.

Spicy foods. Spicy foods temporarily speed up your metabolism. They are associated with taking longer to fall asleep and with more time spent awake at night. This may be caused by the capsaicin found in chili peppers, which affects body temperature and disrupts sleep. Also, in some people, spicy foods can lead to sleep-disturbing gas, stomach cramps and heartburn.

Foods that Help You Sleep

Carbohydrate-based meals increase blood levels of tryptophan, used by the body to manufacture serotonin, a “calming” neurotransmitter. Also helpful…

Warm milk. It’s not a myth—warm milk at bedtime really will help you get to sleep. It settles the stomach, and the ritual of drinking it can help you calm down and fall asleep more easily.

Cherry juice. A study published in Journal of Medicinal Food found that people who drank eight ounces of tart cherry juice in the morning and eight at night for two weeks had about 17 minutes less awake time during the night than when they drank a non-cherry juice. Tart cherries are high in melatonin, a hormone that regulates the body’s sleep-wake cycles. The brand used in the study was Cheribundi.

Helpful: Tart cherry juice has 140 calories in eight ounces, so you may want to cut back on calories elsewhere.