But moments after arriving with his pregnant wife and three children at the foot of the international bridge, he and his family were stopped by Mexican officials and detained.

A few months ago, Mr. Moreno’s lack of proper paperwork would have been ignored by the Mexican authorities, according to local officials and immigration lawyers. But Mr. Moreno was held in a cell for 20 days and his family was placed in a temporary shelter.

The lure of the smugglers in Reynosa is not limited to Central Americans. Mexicans, too, employ their services, although the cost is lower — the prices charged seem to depend on just how bad the situation is in a migrant’s home country.

On a recent day in a migration office in Reynosa, a group of Mexicans sat waiting to be processed after their deportations from the United States.

“For the migration authorities, it is a job,” said Melvin Gómez, 18, who is from the Mexican state of Chiapas. “For Mexicans and Central Americans, immigration is a dream.”

Mr. Gómez had just tried crossing for the fourth time the day before.

“We have something to live for,” he said, “and that keeps us going.”