Dilating (expanding) blood vessels in your head are—at least in part—responsible for triggering headache pain. Caffeine is a natural vasoconstrictor. It shrinks your arteries back down, helping relieve the stabbing and throbbing. That’s why caffeine is an active ingredient in pain relievers made specifically for headaches. A cup of coffee or black tea paired with ibuprofen works, too.