The radio galaxy M87 is the central dominant galaxy of the Virgo Cluster. Very high-energy (VHE, ≳0.1 TeV) emission from M87 has been detected by imaging air Cherenkov telescopes. Recently, marginal evidence for VHE long-term emission has also been observed by the High Altitude Water Cherenkov Observatory, a gamma-ray and cosmic-ray detector array located in Puebla, Mexico. The mechanism that produces VHE emission in M87 remains unclear. This emission originates in its prominent jet, which has been spatially resolved from radio to X-rays. In this paper, we construct a spectral energy distribution from radio to gamma rays that is representative of the nonflaring activity of the source, and in order to explain the observed emission, we fit it with a lepto-hadronic emission model. We found that this model is able to explain nonflaring VHE emission of M87 as well as an orphan flare reported in 2005.