The galaxy M82 has long been considered a promising target for very-high-energy ( VHE ) gamma-ray observations because of the compact starburst region in its core . Theoretical predictions have suggested it should be detectable by ground-based imaging Cherenkov telescopes like VERITAS and that a detection would have implications for the understanding of the origin of cosmic rays . M82 was observed with the VERITAS array during the 2007-2009 observing seasons . With an exposure of 137 hours , VERITAS was able to detect a gamma-ray signal at the 5 \sigma level . This marks the discovery of gamma rays not only from M82 but also from the new source class of starburst galaxies . The observed flux from M82 is ( 3.7 \pm 0.8 _ { \mathrm { stat } } \pm 0.7 _ { \mathrm { syst } } ) \times 10 ^ { -13 } photons cm ^ { -2 } s ^ { -1 } above an energy threshold of 700 GeV , which corresponds to 0.9 % of the Crab Nebula flux . The differential energy spectrum is a power law with a photon index \Gamma = 2.5 \pm 0.6 _ { \mathrm { stat } } \pm 0.2 _ { \mathrm { syst } } . Both the flux and the photon index are close to recent theoretical predictions . The VERITAS data indicate a strong correlation between the star-formation activity and the cosmic-ray production in M82 .