In terms of green chemistry, the use of the use of expired drugs has recently gained attention as sustainable corrosion inhibitors due to their biodegradability, environmental friendliness, low cost, and easy availability. This paper aimed to evaluate the protective action of expired Bepotastine-B on Cu–Zn alloy in simulated cooling water (SCW) using weight loss (WL), Potentiodynamic polarization (PDP), electrochemical impedance spectroscopy (EIS), surface morphology analysis and computer modeling methods, including density functional theory (DFT) and molecular dynamic simulations (MS).The variables concentration, reaction temperature, and pH of an expired drug were examined. The electrochemical results demonstrated that the expired Bepotastine-B is a mixed-type inhibitor that blocks both the anodic and cathodic potentials, which exhibited high inhibition. The corrosion rate falls as the Bepotastine increases and increases as the temperature rises. The drug's adsorption on Cu–Zn alloy follows the Langmuir isotherm model. The examination of surface morphology (SEM/EDX) indicated a formation of an insoluble complex and a fine film of inhibitor, which effectively hinders Cu–Zn alloys from deteriorating, covering the surface. These findings confirmed the formation of an adsorbed layer by the Bepotastine-B molecules hindered the dissolving of Cu–Zn alloys. The inhibitory impact of Bepotastine-B, which investigated, theoretically using DFT and the computational results align well with the results obtained from experimental inhibition efficiencies. The inhibition efficiency (IE) improved with raising Bepotastine-B concentration. The maximum IE of 94.6% has been achieved at 300 mg/L. The combination of experimental and computational approaches enhanced our understanding of the corrosion inhibition mechanism and underscored the potential of Bepotastine-B as a sustainable, and effective corrosion inhibitor for Cu–Zn alloy in this medium at dissimilar temperatures. These findings can serve as a useful guideline for future research aimed at investigating the inhibitory impact of expired drugs as a green one.