Foods that can trigger nightmares include spicy dishes, caffeine, alcohol, and heavy or rich meals before bedtime.