2-Mercaptobenzothiazole (MBT) is an emerging pollutant used as an accelerator in the rubber industries that has been reported to be toxic for humans, causing respiratory paralysis, cancer, and headache. Also, solid waste created by expired and unused medicines is an environmental concern. Hence, to tackle these challenges herein, an efficient, sustainable, and metal-free photocatalyst has been synthesized by combining expired medicine metformin with melamine in a one-pot system, which effectively degraded MBT. First, it provides a solution to the solid waste created by expired drugs, and second, it remediates water pollution caused by MBT. After well characterization, batch studies were performed and revealed that EMCN efficiently eliminates 99.6% of MBT within 24 min and mineralizes it into innocuous products at optimum parameters of MBT concentration of 20 mg/L, catalyst dosage of 10 mg, and pH 5. However, only 29% removal of MBT was observed with CN (graphitic carbon nitride). The statistical parameters (mass: 13.1 mg, pH: 4.6, initial concentration: 21.8 mg/L) of MBT degradation derived from ANOVA using the Box-Behnken design align closely with those observed by batch studies. Moreover, the photodegradation of MBT in sunlight and its recyclability of up to seven cycles make it cost-effective.