Abu Zakariya Yahya

Abu Zakariya Yahya (أبو زكريا يحيى بن حفص, Abu Zakariya Yahya I ben Abd al-Wahid (1203 – 1249) was the founder and first sultan of the Hafsid dynasty in Ifriqiya. He was the grandson of Sheikh Abu al-Hafs, the leader of the Hintata and second in command of the Almohads after Abd al-Mu'min.

Life
He was the Almohad governor of Gabès and then of Tunis by 1228, having inherited this position in Tunisia from his father. And in 1228 he rebelled against his brother AbdAllah which forced him to march from Tunis to Kairouan to confront his brother in battle, but his troops deserted him and Abu Zakariya overthrew him in late June.

Abu Zakariya would again rebel against central authority after he heard that the Almohad caliph in Marrakesh al-Ma'mun, had overthrown and killed two of his brothers and that he cancelled the creed of Ibn Tumart. Additionally, al-Ma'mun instructed the Imams to insult Ibn Tumart in the mosques and cancelled the call to prayer in Berber.

Conquests
Abu Zakariya moved to expand his influence in the vicinity of his young state, and marched his army to Constantine and Béjaïa in 1229.

The Almohads were preoccupied with internal differences and sedition, the revolutions that were taking place in Andalusia and in the Maghreb, so Abu Zakaria faced little resistance in annexing the territory of the Almohads.

Independence from the Almohads
Abu Zakariya returned to Tunis after his successful campaigns and declared independence as king altogether in 1229. He subsequently annexed Tripoli in 1234, Algiers in 1235, Chelif River 1236, and subdued important tribal confederations of the Berbers from 1235 to 1238.

In July 1242 he captured Tlemcen, forcing the Sultan of Tlemcen to become his vassal and formed a series of small states between his rule and the states of the Western Maghreb.

In December of that year, caliph Abd al-Wahid II, died, leaving Abu Zakariya as the most powerful ruler of Maghreb. At this time the Hafsids also occupied the Berber emirate of Siyilmasa which they retained for 30 years. By the end of his reign, the Marinid Dynasty of Morocco and several Muslim princes in Al-Andalus paid him tribute and acknowledged his nominal authority.

Trade and architecture
Abu Zakariyya established his capital in Tunis where mosques, madrasas, souks and other buildings are built. His work was the madrasa al-Shammā'iyya and the mosque of the Kasbah.

He began diplomatic and commercial relations with Emperor Frederick II of Swabia, the Crown of Aragon, Provence, Languedoc, with Venice, Pisa and Genoa. From 1239 he approached the Kingdom of Sicily, in which he paid an annual tribute in exchange for freedom of trade and the supply of Sicilian wheat. As Tunis's maritime trade increased, it became an important economic and cultural center. In the city during his reign took refuge many fleeing the Reconquista, welcoming to his court many notables and scholars of Andalusia.

Abu Zakariyya allowed Jews who had forcibly converted to Islam in the Almohad era to return to Judaism, returning to live in relatively normal conditions. Synagogues closed or destroyed in the Almohad era were reopened or rebuilt. The Jews played a very important role in the economic policy and foreign trade developed by Abu Zakariyya.

A skillful general, his ability to utilize the military power of the tribesmen enabled him to establish a strong state. His Hafsid dynasty brought peace, prosperity, and stability to Tunisia.

His successor Muhammad al-Mustansir, proclaimed himself Caliph in 1256 and continued the policies of his father.