It turns out that caffeine doesn't just affect humans. Several studies, including one recently published in Current Biology, found that some flowers produce caffeine, which leads bees to:

(i) overestimate how good the flower nectar is, aggressively recruiting their colony-mates to come to the caffeinated flower

“The effect of caffeine is akin to drugging, where the honey bees are tricked into valuing the forage as a higher quality than it really is,” Roger Schürch, co-author of the study

(ii) explore other flower options less frequently, returning again and again to the caffeinated site even after it had "closed"-- like a person driving on autopilot to their local Starbucks each morning

"Bees who had been exposed to caffeine returned to their feeder more frequently, and were less likely to investigate the other feeder on their foraging trips out of the hive." -coverage in the Atlantic by Cari Romm

(ii) better remember the flower's scent (aiding their return)

"Honeybees rewarded with caffeine, which occurs naturally in nectar of Coffea and Citrus species, were three times as likely to remember a learned floral scent as were honeybees rewarded with sucrose alone." - findings from a previous study.

What's in it for the flower? More visits from bees-- and thus, more pollination. We tend to think of flowers and pollinators as being in a mutualistic relationship,but there are opportunities for exploitation on either side. Flowers produce caffeine to bias bees, but this is just one example: many others have been reported!

For example, some orchids no longer produce nectar-- the reward bees desire-- while still successfully attracting pollinators. Some orchids mimic the appearance of female bees, attracting amorous males, while other generate alarm pheromones of bees to attract predator wasps. In all of these cases, the orchid gets to save energy, by not producing costly nectar, but still get pollinated.

On the flip side, some bees engage in "nectar robbery," where they drill a hole into the flower at the nectar source and sip up nectar without pollinating the flower.

Through an evolutionary arms race, flowers and their pollinators are constantly competing to get the upper hand. Ain't evolution grand!