The inhibition of corrosion of mild steel using Piper nigrum L in different acid medium by weight loss method was investigated. The corrosion inhibition was studied in hydrochloric acid and sulphuric acid by weight loss method at different time interval at room temperature. The result showed that the corrosion inhibition efficiency of this compound was found to vary with different time interval and different acid concentration. Also, it was found that the corrosion inhibition behavior of Piper nigrum L is greater in sulphuric acid than hydrochloric acid. So, Piper nigrum L can be used as a good inhibitor for preventing mild steel material.