 After the fall of the Western Roman Empire, the monastery of Nostra Signora di Tergu was founded nearby, but the current town originates from the castle built here, in 1102 (or 1270), by the Doria family of Genoa.The castle and the village which gradually formed round it where the seat of the Doria's fiefdom in the island called "Castel Doria" or "Castelgenovese", until it was conquered by the Aragonese in the 15th century (1448), and named "Castillo Aragonés" ("Castel Aragonese").Except for the Maddalena archipelago, it was the last city in the island to join the Kingdom of Sardinia.