The tower and foundations of the castle date back to the end of the 10th century. One finds the first writings which relate the presence of the fortress around 1180. Possession of the Count of Ventimiglia Guido Guerra, it was then ceded to the Count of Provence. Following this sale, from the end of the thirteenth century until the fourteenth century, a cycle of continuous conflicts with the Genoese began. In 1388, Sainte-Agnès and the whole country of Nice will rally to Amédée VII, count of Savoy.