A hostage of five
James was born at Montpellier on 2 February 1208, the only son of Peter II of Aragon and Marie, heiress of the town. The marriage was unhappy, and James later wrote that he owed his very conception to a trick by which his father was brought to his mother's bed. In 1211 Peter handed the boy to Simon de Montfort, leader of the crusade against the Cathar heretics of southern France, as part of a marriage pact. Two years later, on 12 September 1213, Peter was killed fighting Simon at Muret.
Pope Innocent III ordered the child returned, and in 1214 he was handed over and placed with the Knights Templar in their castle at Monzón, in Aragon. His great-uncle, Count Sancho, governed in his name while the nobles of Aragon and Catalonia fought each other. In 1221 he was married to Eleanor, daughter of Alfonso VIII of Castile. By the late 1220s, though still young, he had taken control of his kingdoms and was looking for a great enterprise.
Majorca, 1229
The Balearic Islands were ruled by an Almohad governor, and their ships raided Catalan trade. At a meeting of the Catalan estates in Barcelona in December 1228, nobles, bishops and merchants agreed to back an expedition, in return for shares of the land. The fleet sailed in early September 1229 and landed at Santa Ponsa. After a siege of more than three months, Madina Mayurqa, the city of Majorca, was stormed on 31 December 1229, with great slaughter. Resistance in the hills went on until 1232.
Minorca chose to submit: in 1231 its Muslim leaders accepted James as overlord and agreed to pay tribute, and they kept their island for another half-century. Ibiza was taken in 1235 by a force led by the archbishop-elect of Tarragona. Majorca was settled by Catalans and became a busy port between Barcelona and North Africa. In 1235 James, his first marriage annulled, married Violant, daughter of King Andrew II of Hungary.
The kingdom of Valencia
Valencia had its own Muslim rulers. Its Almohad governor, Abu Zayd, driven out in 1229 by a rival, Zayyan ibn Mardanish, became James's vassal and ally, and later a Christian. James advanced down the coast: Burriana fell in 1233, and in 1237 his men held the hill of El Puig, in sight of the city, against Zayyan's attack. The siege of Valencia began in April 1238. The city surrendered on 28 September, and on 9 October James entered it. Its Muslim people were allowed to leave with what they could carry.
The south of the kingdom took longer. In 1244, at Almizra, James and the heir of Castile, the future Alfonso X, drew the border between their conquests. Xàtiva came to terms the same year and Biar fell in 1245. Most of the countryside stayed Muslim, now as Mudejars under treaties that left them their mosques, law and judges. James made Valencia a separate kingdom, not part of Aragon or Catalonia, with its own code of fueros, the Furs.
Revolts and treaties
The treaties did not hold everywhere. From 1247 a Muslim leader known as al-Azraq led a revolt in the mountains of the south that lasted, on and off, for about a decade. James answered by ordering the Muslims of the kingdom expelled, but the order was only partly carried out, since landlords needed their labour. In 1258, by the treaty of Corbeil, he gave up his family's claims in southern France, except Montpellier, while Louis IX gave up the French crown's old claims to Catalonia.
In 1264 the Mudejars of Andalusia and Murcia rose against his son-in-law Alfonso X. James marched into Murcia, took the city early in 1266 and handed it back to Castile, as the treaty of Almizra required. In 1269 he set out on crusade for the Holy Land, but a storm scattered his fleet and he turned back. His last years were troubled by quarrels among his sons and by a new Muslim rising in Valencia, during which he fell ill.
The Book of Deeds
James died on 27 July 1276, in the kingdom he had conquered, and was buried in the Cistercian abbey of Poblet, in Catalonia. As he had arranged, his lands were divided: Peter III took Aragon, Catalonia and Valencia, and James II received Majorca, Roussillon and Montpellier as a separate kingdom. He left the Llibre dels fets, the Book of Deeds, which he dictated in Catalan in the first person, probably in two stages, in the 1240s and in the last years of his life.
The book tells his wars as he wished them remembered, with sieges, councils, quarrels with nobles and many conversations reported word for word. It is a source from the Christian side and from one man, but an unusually lively one, and it is one of the first great works of Catalan prose. It is often called the first autobiography of a medieval king. That is not quite right: a century and a half earlier, Abd Allah ibn Buluggin, the last Zirid emir of Granada, had written his memoirs in Arabic in exile.