The moat, which surrounded the Iberian town of Vilar de Vals, contained coins and lead projectiles, researchers said in a statement.
It is estimated the moat could have had a width of 40 metres (131 feet), a depth of five metres, and a length of nearly half a kilometre.
The huge dimensions of the trench surprised the directors of the investigation, Jaume Noguera from the Prehistory department at the University of Barcelona, and Jordi López, from the Catalan Institute of Classic Archeology, according to Catalan newspaper, La Vanguardia.
Noguera and López said the site may have been destroyed by the Romans during the Second Punic War (218-202 BC) that pitted Rome against Carthage for the hegemony of the Mediterranean.
Hannibal, one of the most famous military commanders in history, crossed the Pyrenees with his soldiers and elephants, traversing the Iberian Peninsula, before reaching present-day Italy in 218 BC.
He left around 11,000 men in Spain to protect his interests in the north of Iberia and to guarantee a regular source of food and weapons to his troops.
But Roman legionnaires, led by general Gnaeus Cornelius Scipio Calvus, defeated Hannibal’s men in Iberia. After the battle, the Romans raided a nearby Carthaginian camp, located on the edge of a town, and destroyed everything.
The camp and town were located in modern-day Valls in Catalonia, where the group of archaeology students from the University of Barcelona made the discovery.
They tested the age of the moat using electrical resistivity tomography, a technique that involves analyzing sub-surface structures from electrical resistivity measurements made at the surface.
The students’ fieldwork is part of an attempt to reconstruct the route taken by Carthaginian troops through north-eastern Spain and their confrontation with Rome.