Mexico agreed Monday to deport Cubans who sneak illegally through Mexican territory to reach the U.S., a step toward cutting off an increasingly violent and heavily used human trafficking route.

The agreement signed by Cuban Foreign Minister Felipe Perez Roque and Mexican Foreign Secretary Patricia Espinosa also criticized U.S. policy that generally allows Cubans who reach U.S. territory to stay, while turning back most caught at sea.

Cuban migrants in recent years have increasingly headed for Mexico — often to the coast near Cancun — then overland to Texas because it has become so hard to dodge the U.S. Coast Guard and reach Florida to qualify for U.S. residency.

The Department of Homeland Security said 11,126 used the Mexico route last year, compared to just 1,055 who landed in the Miami area.

Before Monday, Mexico rarely sent back Cubans caught entering the country illegally. Many were held for a time, then were given 30-day transit visas to continue on to Texas, where Cubans present only identity documents and undergo medical and background checks before being welcomed to America.

Under the new agreement, Mexico agreed to deport Cubans found illegally in Mexico, both those that arrive from their native island by boat and those come up through Central America.

Cuba agreed to a mechanism for accepting the deportees.

Perez Roque said the agreement would lead to "the immense majority of Cubans being repatriated." Some 2,000 Cubans are currently being held in Mexican immigration detention centers.

"I am sure that this memorandum of understanding is going to significantly reduce attempts to use Mexico as a route to getting to the United States," he said.

Mexico has grown increasingly frustrated with the Cuban migration, which often involves ruthless human trafficking gangs.

In June, gunmen snatched 33 Cubans off a government bus headed to an immigration station in southern Mexico, possibly to extort money from them or their smugglers. Many of those migrants later turned up in the U.S.

All detained Cuban migrants now have armed police escorts.

Several Cuban-Americans believed to be involved in smuggling have been killed in recent years in or around Cancun, and smugglers have stolen hundreds of speedy boats from Florida docks for use in the trade.

Perez Roque said his visit to Mexico was a sign of improved relations between the two countries.

Espinosa agreed, saying that trade between Cuba and Mexico had increased 79 percent in the first eight months of this year, compared to the same period a year before.

"Neighboring friendly countries need to support each other," she said.

Ties between the communist island and Mexico soured under the 2000-2006 presidency of Vicente Fox, when Mexico voted in the U.N. in favor of monitoring human rights in Cuba. Relations reached a low in 2004, when both countries called home their ambassadors.