The main protease (Mpro) of coronaviruses participates in viral replication, serving as a hot target for drug design. GC376 is able to effectively inhibit the activity of Mpro, which is due to nucleophilic addition of GC376 by binding covalently with Cys145 in Mpro active site. Here, we used fluorescence resonance energy transfer (FRET) assay to analyze the IC50 values of GC376 against Mpros from six different coronaviruses (SARS-CoV-2, HCoV-229E, HCoV-HUK1, MERS-CoV, SARS-CoV, HCoV-NL63) and five Mpro mutants (G15S, M49I, K90R, P132H, S46F) from SARS-CoV-2 variants. The results showed that GC376 displays effective inhibition to various coronaviral Mpros and SARS-CoV-2 Mpro mutants. In addition, the crystal structures of SARS-CoV-2 Mpro (wide type)-GC376, SARS-CoV Mpro-GC376, MERS-CoV Mpro-GC376, and SARS-CoV-2 Mpro mutants (G15S, M49I, S46F, K90R, and P132H)-GC376 complexes were solved. We found that GC376 is able to fit into the active site of Mpros from different coronaviruses and different SARS-CoV-2 variants properly. Detailed structural analysis revealed key molecular determinants necessary for inhibition and illustrated the binding patterns of GC376 to these different Mpros. In conclusion, we not only proved the inhibitory activity of GC376 against different Mpros including SARS-CoV-2 Mpro mutants, but also revealed the molecular mechanism of inhibition by GC376, which will provide scientific guidance for the development of broad-spectrum drugs against SARS-CoV-2 as well as other coronaviruses.