The effectiveness of 3-nitrobenzoic acid towards the inhibition of the corrosion of mild steel and aluminium in solution of HCl was investigated using theoretical and experimental methods (weight loss, thermometric, polarization, FTIR and SEM techniques). Inhibition efficiency of 3-nitrobenzoic acid, evaluated from weight loss technique ranged from 71% to 90% and from 71% to 82% for mild steel and aluminium, respectively. Results from linear polarization and potentiodynamic studies were comparable to weight loss results. Calculated kinetic (activation energy), thermodynamic (changes in entropy and enthalpy) and adsorption parameters indicated that the adsorption of the inhibitor on the surface of the respective metal is accompanied by molecular association and is endothermic, spontaneous and favoured the mechanism of physical adsorption. Best-fitted adsorption isotherms were Langmuir and Frumkin models, which gave evidences for the existence of interaction, characterized by attractive behaviour of the inhibitor on both mild steel and aluminium surfaces. Scanning electron micrographs of the metal before and after inhibition clearly revealed that the inhibitor prevented crevice and pitting corrosion by forming adsorbed protective layer on the respective metal surface. FTIR spectra of the inhibitor and the corrosion products indicated the formation of new bond, existence of interaction between the inhibitor molecules and the involvement of some functional groups in the adsorption and inhibition processes. Quantum chemical study revealed that the inhibitor is adsorbed on the metal surface through the nitro functional group in the ring. Calculated semi empirical parameters were comparable to those reported for excellent corrosion inhibitors.