Real-time monitoring of neurotransmitters can offer critical information for understanding neural functions and diagnosing diseases. Herein, a flexible electrochemical biosensor suitable for detecting serotonin (5-HT) in different bodily fluids was developed based on vertical graphene co-doped with boron and nitrogen (BNVG). BNVG nanosheets were vertically grown on flexible tantalum substrates via chemical vapor deposition. The electrochemically active sites were regulated by changing the B and N contents in the BNVG film. The BNVG-based biosensor exhibited a quantitative response toward 5-HT in the pH range of 1.5–9.0. The linear concentration range of 5-HT depends on the pH, with the widest measurable concentration ranging from 0.10 to 224.43 μM. The range of 5-HT detection limits (S/N = 3) was 0.009–0.266 μM. The BNVG-based biosensor detected 5-HT in gastric juice, intestinal juice, and blood samples with high sensitivity and stability. The well-designed flexible BNVG-biointerface is an effective biosensor platform for detecting the neurotransmitter 5-HT, which can aid the development of neural electrodes and medical-care products.