OTTAWA -- Prime Minister Justin Trudeau says Canada is ready to help "our friends" in Mexico following a magnitude 7.1 earthquake that killed dozens and collapsed buildings.

Calling the quake in central Mexico "devastating," Trudeau said on Twitter that his thoughts are with those affected by the disaster.

The U.S. Geological Survey said the quake was centred near the Puebla state town of Raboso, about 123 kilometres southeast of Mexico City.

The Canadian Embassy in Mexico tweeted out an emergency phone number and email for any Canadians needing assistance.

And Global Affairs said it was closely monitoring the situation in Mexico and was ready to help.

Tuesday's earthquake came less than two weeks after another quake left 90 dead in the country's south, and it occurred as Mexicans commemorated the anniversary of a 1985 quake that killed thousands.

With files from The Associated Press