Alfonso X, El Sabio, or the learned, (November 23, 1221 - April 4, 1284) was a king of Castile and León (1252 - 1284). He is perhaps the most interesting, though far from the most capable, of the Spanish kings of the Middle Ages.
He was a writer, and he had considerable scientific fame, based mainly on his encouragement of astronomy and the Ptolemaic cosmogony as known to him through the Arabs. The Alphonsus crater on the Moon is named after him.
He established at Toledo a translation school that did a great work in bringing the knowledge of the Arabs and Jews into Christian Europe. Much of it was based on Classical philosophy.
As a ruler he showed legislative capacity, and a very commendable wish to provide his kingdoms with a code of laws and a consistent judicial system. The Fuero Real was undoubtedly his work, and he began the code called the Siete Partidas, which, however, was only promulgated by his great-grandson. He lacked the singleness of purpose required by a ruler who would devote himself to organization, and also the combination of firmness with temper needed for dealing with his nobles. His descent from the Hohenstaufen through his mother, a daughter of the emperor Philip of Swabia, gave him claims to represent the Swabian line. The choice of the German electors, after the death of Conrad IV in 1254, misled him into wild schemes which never took effect but caused immense expense. To obtain money he debased the coinage, and then endeavoured to prevent a rise in prices by an arbitrary tariff. The little trade of his dominions was ruined, and the burghers and peasants were deeply offended. His nobles, whom he tried to cow by sporadic acts of violence, rebelled against him.
His second son, Sancho, enforced his claim to be heir, in preference to the children of Ferdinand de la Cerda, the elder brother who died in Alfonso's life. Son and nobles alike supported the Moors, when he tried to unite the nation in a crusade; and when he allied himself with the rulers of Morocco they denounced him as an enemy of the faith. A reaction in his favour was beginning in his later days, but he died defeated and deserted at Seville, leaving a will by which he endeavoured to exclude Sancho and a heritage of civil war.
In addition to his other achievements, Alfonso X commissioned or co-authored numerous works during his reign, including the Cantigas de Santa Maria (400+ songs mentioning the Virgin Mary, Galician-Portuguese) and the Libro de los juegos, or "Book of Games".