The adsorption and inhibition effects of 5-nitro-1H-benzimidazol-2(3H)-one (P2) on mild steel corrosion in 1 M HCl have been studied by electrochemical and weight loss methods. Results obtained showed that inhibition efficiency increases with concentration and maximum value was obtained at 10–3 M concentration. From the results, it is concluded that compound P2 inhibited mild steel corrosion in 1 M HCl by adsorbing on the metal surface. Polarization results showed that P2 act as mixed type inhibitor. The adsorption of P2 onto the mild steel surface was described by the Langmuir adsorption isotherm.