Immigrant deportations in the United States fell to the lowest level seen since 2007, marking the second consecutive year that forced removals declined sharply under the Obama administration.

The federal government deported 333,341 undocumented immigrants in the last fiscal year, according to new data released from the Department of Homeland Security. The numbers represent a nearly 20 percent decline in deportations from the year prior, when the Obama administration removed 407,075 undocumented immigrants.

However even with those declines, President Obama remains the most aggressive enforcer of federal immigration laws in modern U.S. history. More than 2.8 million undocumented immigrants were deported under Obama’s tenure. It outpaces deportations carried out by his predecessor, President George W. Bush, by almost a million.

One explanation behind the declining deportations in the waning days of the Obama administration is that fewer immigrants, both legal and not, are entering to the U.S. in the first place.

According to analysis conducted by the Pew Research Center, net migration from Mexico has neared zero. More people were leaving to Mexico than those coming to the U.S., Pew researchers found, largely due to the great recession of 2008.

The new statistics also reflect how migration patterns along the U.S-Mexico border have changed since Obama first assumed office. For years Mexican migrants drove up the undocumented population to an all-time high of 12.2 million people.

However Central Americans now represent the largest share of immigrants intercepted at the border. Many are openly presenting themselves to border patrol agents, asking for asylum.

The dynamic has meant that a large share of people coming to the U.S. without authorization must still be given temporary protection as their asylum claims work their way through the immigration courts. The process often takes months to years, meaning the U.S. can immediately deport only a portion of the immigrants apprehended at the border.

President Obama’s 2014 directives to prioritize federal immigration resources is also likely a factor in last year’s decline. Immigration and Customs Enforcement officials were told to focus enforcement efforts on those with criminal convictions and recent border crossers. Last year 139,950 immigrants, or more than 40 percent of those deported, had some type of prior criminal conviction.