The city has a long history and was once an important Roman town along the ancient Via Flaminia road. It was known first in antiquity as Tadinum, and later by the name of Taginae. It was under the latter name that it is best known to history. In 552, the Byzantine general Narses briefly restored Italy to the empire by defeating the Ostrogoth king Baduila in what is now known as the Battle of Taginae.
The ancient city survived that war, only to be destroyed in a later war at the instigation of the Holy Roman Empire Otto III in 966. It was later rebuilt, only to be destroyed a second time by fire in 1237. Finally, the Emperor Frederick II ordered the city rebuilt for a third time in 1239, and it is this incarnation which survives today.