Yes, caffeine is beneficial for cyclists. Studies show that consuming caffeine prior to exercise may result in improved performance, speed, power, and endurance capacity .
Caffeineis a central nervous system stimulant that works by blocking adenosine and is found naturally in coffee, tea, and chocolate.
The recommended dose is 3-9 mg caffeine/kg, 30 - 90 minutes before cycling, which equates to 1-2 cups of brewed coffee for most people. Cyclists can consume up to 400-500mg caffeine/day (about 4-5 cups of coffee) to reap the performance benefits, but exceeding this amount may lead to negative side effects, like jitteriness or heart palpitations. Studies show that omitting caffeine or limiting intake to 50 mg/day 2-7 days before a race may maximize the benefits of caffeine on race day [ 2 3
 Jonathan D. Wiles, Damian Coleman, Michael Tegerdine & Ian L. Swaine (2006) The effects of caffeine ingestion on performance time, speed and power during a laboratory-based 1 km cycling time-trial, Journal of Sports Sciences, 24:11, 1165-1171, DOI: 10.1080/02640410500457687
Kerksick, C.M., Wilborn, C.D., Roberts, M.D. et al. ISSN exercise & sports nutrition review update: research & recommendations. J Int Soc Sports Nutr 15, 38 (2018).
 Jane Shearer, Terry E Graham, Performance effects and metabolic consequences of caffeine and caffeinated energy drink consumption on glucose disposal, Nutrition Reviews, Volume 72, Issue suppl_1, 1 October 2014, Pages 121–136, https://doi.org/10.1111/nure.12124