WASHINGTON—The Trump administration ramped up arrests of undocumented immigrants in 2017, but the number of deportations fell below even the lowest level recorded during the Obama administration, the government said Tuesday.

That is largely because the number of people caught crossing the border illegally plummeted to the lowest level since 1971, according to the Department of Homeland Security, meaning there were fewer people to deport. At the same time, undocumented immigrants arrested inside the U.S. were caught in a growing...