It has to do with the enzyme in your body responsible for breaking down caffeine, per a 2001 study published in the National Academies Press — more specifically, the cytochrome P450 1A2.
“Researchers suggest that hormonal birth control may inhibit the enzyme which breaks down caffeine, so that caffeine tends to stay in the system of women using birth control longer than it would in other women. So, the same amount of caffeine could hit you twice as hard if you’re on birth control,” explained nutritionist Emma Thornton (via A.Vogel). Something else that was observed in the study was how this common medication reduced the diuretic effect of caffeine in the women who were on it, according to Thornton. Women on the pill who’ve consumed energy drinks might also be more sensitive to the side effects from the caffeine boost, and this could manifest in jitteriness, increased heartbeat, and headache, per WebMD.
With that said, birth control pills aren’t the only things that affect caffeine sensitivity in women.