Ceuta officials said 498 migrants were counted climbing over the high border fence into the Spanish North African territory. A total 700 had attempted to cross, they said.
Moroccan authorities said 250 people tried to get across, of whom 110 were detained and around 20 injured.
In Ceuta, officials said two migrants and 11 officers were hurt.
Footage shot by the local Faro de Ceuta television showed dozens of euphoric migrants wandering the streets of the seaside enclave, ecstatic to have finally crossed into a European Union state.
Ceuta and Melilla, also a Spanish territory in North Africa, have the EU's only land borders with Africa, so are entry points for migrants who either climb the border fence, swim along the coast or hide in vehicles.
Emergency services said on Twitter that 400 people were receiving assistance from the Spanish Red Cross.
The massive entry, one of the biggest since the border barrier was reinforced in 2005, comes amid a dispute between Morocco and the EU over the interpretation of a free trade farm and fishing deal.
The court said this was because the status of the disputed territory remained unclear according to the international community.
The 28-nation bloc did not recognise it as part of Morocco.
The ruling opened the way for the Polisario Front and its supporters to contest trade in products from the Western Sahara between Morocco and the 28 EU states.
The decision angered Morocco, which in a warning on February 7 suggested it could lead to "a new flow of migration" towards Europe and place the continent "at risk".
The enclave has been ringed by a double wire fence that is eight kilometres long. The six-metre high fence also has rolls of barbed wire.
Disclaimer: No Business Standard Journalist was involved in creation of this content
