Mexican President Claudia Sheinbaum pledged Thursday that soldiers who opened fire and killed six migrants, apparently mistaken for criminals, would face justice.
The killings late Tuesday during a highway chase in southern Chiapas state "must be investigated and punished," Sheinbaum said, adding that the victims were from Egypt, El Salvador and Peru.
The state prosecutor's office would investigate the incident, including whether commanders were also responsible, she told a news conference.
"A situation like this cannot be repeated," she added.
Peru called for "an urgent investigation" into what it called a "reprehensible act."
In recent years, Mexico has given an increased public security role to its military, which human rights group Amnesty International in April accused of using "unnecessary and excessive force."
The United Nations human rights office earlier this week voiced concern about "the growing role that the military has taken in public security and other law enforcement functions."
Migrants "are exposed to great risks during their journey, which is why it is essential to have legal pathways for access, transit and integration to avoid tragedies like this one," it said Wednesday in response to the six deaths.
The shooting happened on the same day that Sheinbaum was sworn in as president, vowing to respect human rights and avoid repression by security forces.
According to a police report, soldiers chased a truck after it failed to stop at an army checkpoint, firing gunshots to try to stop it.
The defense ministry said the two soldiers who opened fire had been removed from their duties pending an investigation.
It said a military patrol saw a vehicle -- followed by two flatbed trucks similar to those often used by criminals -- traveling at high speed and apparently attempting to flee.
"Military personnel reported hearing gunshots, so two soldiers activated their weapons, stopping one of the flatbed trucks," the statement said.
The patrol found 33 migrants from countries that also included Nepal, Cuba, India and Pakistan.
Four of the migrants died at the scene while two of the 12 injured lost their lives at the hospital, it said.
Chiapas, home to lush jungle, Indigenous communities and ancient Mayan ruins, has seen intensifying turf wars between two powerful cartels involved in drug and people smuggling.
Thousands of migrants from many countries travel through Mexico each year in buses, overcrowded trailers operated by people smugglers and on freight trains in an attempt to reach the US-Mexican border.
They run the risk of fatal accidents, kidnapping by criminal groups and extortion by corrupt officials.
In December 2021, 56 migrants, most of whom were from Central America, were killed and dozens injured when a truck carrying around 160 people overturned in Chiapas.
More than 9,800 migrants have died or disappeared in the Americas since 2014, most of them while trying to reach the United States via Mexico, according to the International Organization for Migration.