The extraction efficiency of stimulant drug, namely caffeine, was investigated using a 23 central composite design. The values of optimum extraction condition were set at 468 μL of 1-dodecanol, 1 piece of effervescent tablet, and 22 °C of extraction temperature. An enrichment factor was calculated as 72 for 80 mL water sample. The run time was conducted in less than 6 min using a non-polar C18 column and an isocratic mobile phase (methanol: water of 40:60 (v/v)) at a controlled flow rate of 1 mL min-1. A good linear response was achieved in the range of 0.01-0.50 μg mL-1 (R2> 0.998). Detection and quantification limits were calculated at 0.009 and 0.015 μg mL-1, respectively. The average recoveries at two spiking concentration levels were within the range of 75-105% with RSD < 2% (n = 3). Real samples namely beverages which contained caffeine and river water were tested using the proposed method, and the results ranged 0.021-0.56 μg mL-1. The eco-scale score and green analytical procedure index confirmed the greenness profile of the proposed method through a calculated score of 88 and has 6 green criteria, respectively.