Police in Spain have arrested five people accused of charging migrants thousands of dollars to take them to mainland Europe from Ceuta, the Spanish territory in northern Africa that has seen a deadly migrant rush.

The alleged traffickers charged migrants up to $10,500 to transport them by boat from Ceuta to the Iberian peninsula, Spanish police said in a statement.

An estimated 72,000 irregular migrants entered the small enclave in late July, swimming or crossing on foot from neighbouring Morocco in a chaotic influx that left scores dead and sparked European Union infighting over the touchy issue of migration.

Four of those arrested belonged to a trafficking network that intercepted irregular migrants, housed them in residences or garages in Ceuta, then took them across the Strait of Gibraltar to southern Spain, police said.

"Boat drivers were selected for their experience navigating fast and their ability to take evasive manoeuvres and dodge police checks," the statement said.