Due to its stimulatory effects, caffeine is one of the most frequently consumed mood and behavior altering drugs. University students report using caffeine-containing products to enhance mood and performance or for a desire of alertness. The current study investigated caffeine consumption in university undergraduate students, and associations with smoking status, alcohol and cannabis consumption, fruit and vegetable consumption, and sleep quality. Motivations for caffeine intake were also ascertained. A total of 886 undergraduates aged 18–25 years from the University of the Balearic Islands participated in a cross-sectional survey. Caffeine was consumed by 91.1% of participants. Caffeine consumers were more likely to be female, smokers, and alcohol and cannabis consumers. Coffee was found to be the main source of caffeine intake in both men and women (48.9% of total caffeine intake). Higher percentages of women consumed coffee (56.4 vs. 42.1%, p = 0.01) and tea (40.3 vs. 19.8%, p < 0.001), whereas a higher percentage of men consumed energy drinks (18.0 vs. 7.4%, p < 0.001). Main motivations for caffeine intake were those related to cognitive enhancement. Caffeine intake was associated with poorer subjective sleep quality (p < 0.001). In conclusion, undergraduate students that were female and smokers reported higher caffeine intakes. Coffee was found as the main caffeine contributor, with higher contributions of tea in women and energy drinks in men. Universities should consider the implementation of health campaigns and educational programs to educate students of the risks of high caffeine consumption together with associated behaviors such as smoking, alcohol consumption and poor sleep quality to physical health and academic performance.