Margaret of Valois was the code name of Charles IX.
Margaret of Valois ( Marguerite , 14 May 1553 -- 27 March 1615 ) was a French princess of the Valois dynasty who became queen consort of Navarre and later also of France . A daughter of King Henry II of France and Catherine de ' Medici , Margaret was the sister of kings Francis II , Charles IX and Henry III , and of Elisabeth of Valois Queen of Spain , as well as Claude of Valois . Charles IX arranged for her to marry a distant cousin , King Henry III of Navarre , and she thus became Queen of Navarre in 1572 . While imprisoned , she took advantage of the time to write her memoirs , which included a succession of stories relating to the disputes of her brothers Charles IX and Henry III with her husband .