More Mexicans are leaving the United States than entering it according to a report released on Thursday, at a time when some Republicans, including presidential candidate Donald Trump, have taken a hard line on illegal immigration.

Most Mexicans leaving the United States are doing so voluntarily to reunite with their family or to start one, the report by the Pew Research Center showed.

From 2009 to 2014, more than one million Mexicans and their families left the United States for Mexico, while more than 865,000 entered the United States, Pew said. The figures include unauthorized immigrants.

An increasing share of Mexicans says life north of the border is neither better nor worse than life in Mexico, Pew said.

The overall flow of Mexican immigrants between the two countries is at its smallest since the 1990s, Pew said.

The findings follow Trump's call for mass deportation of undocumented immigrants, a plan President Barack Obama has said is too costly and un-American.

Trump, a real estate billionaire who has been among the leading candidates for the Republican nomination in the presidential 2016 election, also said he would get the Mexican government to pay for building a wall along the border.

More than 16 million Mexican immigrants have migrated to the United States in the last 50 years, more than from any other country, Pew said.

From fewer than 1 million living in the United States in 1970, the number of Mexican immigrants peaked at 12.8 million by 2007, Pew said. The total declined to 11.7 million last year.

The drop is mostly due to a decrease of more than 1 million unauthorized immigrants from a peak of 6.9 million in 2007 to 5.6 million in 2014, Pew said. Still, unauthorized immigrants from Mexico account for about half of all U.S. unauthorized immigrants.