Carbon dot-based fluorescence sensors have attracted research interest for the selective determination of anti-inflammatory drugs in biological fluids and environments. The overdose and accumulation of anti-inflammatory drugs in tissues can cause chronic side effects including abdominal pain, and renal damage. Herein, we report a new fluorescent probe, bamboo stem waste-derived carbon dots (BS-CDs) for highly sensitive detection of Flufenamic acid (FA), a hazardous anti-inflammatory drug. The UV–vis absorption spectra of BS-CDs show a redshifted absorption peak at 283 nm upon the addition of FA suggesting strong binding interaction between BS-CDs and FA molecule. The BS-CDs showed a fluorescence enhancement (∼2-fold) detection for FA (400 μM) in the linear concentration range (0.40 → 0.65 μM) with a limit of detection (LoD; 17 nM) and binding constant (Ka = 1.33 × 10−3 M−1). The time-resolved fluorescence decay analysis showed that the average lifetime of BS-CDs has slightly changed (4.42 → 4.67 ns) by the interaction with FA through the aggregation-induced emission (AIE) process. The interference, pH, and effect of time results suggest that BS-CDs are highly selective probes for FA detection and do not show any interference involvement during FA detection. The confirmation of the structure and morphology changes of BS-CDs after interaction with FA was carried out by XRD, FESEM, HRTEM, FTIR, and Raman spectroscopy. The practicability of the BS-CDs probe was proved by the detection of FA in human urine samples with recovery of 103–109 %. This suggests that the proposed BS-CDs-based ‘turn-on’ sensor could be used to determine the FA in biological fluids.