Melatonin can be sensitively detected in pharmaceuticals by cyclic voltammetry and fixed-potential amperometry using a graphene-based sensor. The sensor characterization of cyclic voltammetry constantly provides high values of electrode active area and heterogeneous rate constant. In optimal conditions, the sensor was applied for the determination of melatonin in different pharmaceutical samples. The sensitivity to melatonin was 0.0371 A M
−1
, and the limit of detection was 0.87×10
−6
M. The data obtained by using the graphene-based sensor for the detection of melatonin in pharmaceutical products were in good agreement with the data provided by the producer. Since no interferences from the excipients were found, using a separation technique was not necessary. Additionally, the low price, ease of handling, small amount of sample, short time per analysis, and possibility of automation are the important advantages that recommend this methodology for quality control of pharmaceuticals.