Around 40 migrants a day were detained after crossing the Channel from France to Britain last summer, according to an official report, which criticised the authorities' response as "inadequate".
The report by HM Inspectorate of Prisons (HMIP), which contained figures on arrivals that are not normally made public, showed 3,603 migrants were detained in July, August and September at the height of a surge in numbers attempting to cross the Channel.
The migrants arrived in Britain hidden in vehicles on cross-Channel ferries or on freight trains using the Eurotunnel, the report said.
Most were held at a facility at Dover Seaport, with the rest detained at an overflow facility in nearby Folkestone.
"There is no doubt that the increases in migration initially overwhelmed the existing facilities and an emergency response was required," said chief inspector Peter Clarke.
"It was unacceptable that arrangements were still not in place to process detainees quickly, efficiently and decently, while ensuring that the most vulnerable, such as children, were safe and that the basic physical needs of all detainees for food, rest and clothing were met."
The report did not say how many of the migrants made asylum claims or were returned.
Immigration Minister James Brokenshire accepted that the use of an overflow facility "was not acceptable" and insisted it would not be used in the same way in the future.
"Since this inspection we have improved the facilities at Dover Seaport and continue to work on plans to open a new centre to deal with clandestine arrivals at Kent ports," he said.
Immigration has once again become a hot topic in Britain as it prepares to vote on whether to stay in the European Union.
Prime Minister David Cameron's office warned yesterday that a so-called Brexit could mean migrant camps being set up on British shores if UK border checks were removed from Calais.
"Should Britain leave the EU there's no guarantee those controls would remain in place," Cameron's spokesman said at a daily briefing last month.
"If those controls weren't in place there would be nothing to stop thousands of people crossing the Channel overnight and arriving in Kent (southeast England) and claiming asylum," he said.