Ferdinand IV (born December 6, 1285, Sevilla—died September 7, 1312, Jaén, Andalusia) was the king of Castile and Leon, succeeding his father, Sancho IV, in 1295.
Ferdinand survived his minority through the tact and bravery of his mother, María de Molina, who acted as regent. He was further aided by the loyalty of the citizens of Ávila, where he took refuge during an anarchic period marked by conspiracies and rebellions of the Castilian nobility against the crown. Upon coming of age, Ferdinand rejected his mother’s guidance but proved to be a weak king. His forces recaptured Gibraltar from the Moorish kingdom of Granada in 1309.