Given its premiere at the Salle Le Peletier on 11 March 1867 , the opera 's story is based on conflicts in the life of Carlos , Prince of Asturias ( 1545-1568 ) , after his betrothed Elisabeth of Valois was married instead to his father Philip II of Spain as part of the peace treaty ending the Italian War of 1551-1559 between the Houses of Habsburg and Valois .
It was part of the peace treaty ending the Italian War of 1551-1559 between the Houses of Habsburg and Valois .