Dozens of pro-Palestinian students from Mexico's largest university camped out Thursday in solidarity with similar protests that have swept colleges in the United States.

Mounting flags and chanting "Long live free Palestine," the protesters set up tents in front of the National Autonomous University of Mexico's (UNAM) head office in Mexico City.

The students called on the Mexican government to break diplomatic and commercial ties with Israel.

"We are here to support Palestine, the people who are in Palestine, and the student camps in the United States," said Valentino Pino, a 19-year-old philosophy student.

Jimena Rosas, 21, said she hoped the protest would have a domino effect and spread to other universities in the country.

"Once people see that UNAM is beginning to mobilize, other universities should start as well," she said.

Dozens of universities in the United States have seen pro-Palestinian demonstrations in recent weeks, leading to clashes with police and counter-protests.

The Gaza war started when Hamas militants staged an unprecedented attack on Israel on October 7 that left around 1,170 people dead, mostly civilians, according to an AFP tally of Israeli official figures.

Israel's retaliatory offensive has killed more than 34,500 people in Gaza, mostly women and children, according to the Hamas-run territory's health ministry.