The Emirate of Nekor or à ÂÃÂlihid Emirate () was an Arab emirate centered in the Rëf area of present-day Morocco. Its capital was initially located at TamsÃÂmÃÂn, and then moved to Nekor. The ruling dynasty was as of Himyarite Arab descent. The emirate was founded in 710 CE by à ÂÃÂlih ibn Mansà «r through a Caliphate grant. Under his guidance, the local Berber (Amazigh) tribes adopted Islam, but later deposed him in favor of one DÃÂwà «d al-Rundë (unlikely to have been a native of Ronda) from the Nafza tribe. They subsequently changed their mind and reappointed à ÂÃÂlih ibn Mansà «r. His dynasty, the Banà « à ÂÃÂlih, thereafter ruled the region until about 1015.
Several successive political entities controlled the Rëf In the period between the 8th and 14th centuries. The Emirate of Nekor, established at the beginning of the 8th century, ended with the destruction of its capital city Nekor in 1080. The area was integrated subsequently into the dominions of the Almoravids, and then those of the Almohads and the Marënids.
The Emirate of Nekor (or Nakà «r) was the first autonomous state in the Maghreb and the only one that adhered to Sunni Islam exclusively, specifically the Maliki school. Not much is known about the town of Nekor's archaeology outside the field survey and minor excavations conducted in the 1980s. The town has what may have been a mosque, a possible hammam, or public bathhouse, and two substantial walls. Ceramics excavated there include local productions and others that show its connections with Ifrëqya and al-Andalus.
The Arab conquest of North Africa began in 648, bringing Islam, thereafter the predominant religion of the region. 'Uqba ibn NÃÂfi (662âÂÂ683) was the leader of the Muslim conquest of the Maghreb. When his troops attacked local mountain Berber tribes, Arab reinforcements appeared in the Rëf to join them. One of these groups was led by a South Arabian called à ÂÃÂlih ibn Mansà «r al-Himyari, who founded the Banà « à ÂÃÂlih dynasty in 710, ruling until 749. His putative south Arabian origin is disputed by al-Ya'Ã·à «bi, who associates him with the Nafzë Berber tribe in his KitÃÂb al-BuldÃÂn (Book of Countries). The à ÂÃÂlih family founded the Emirate of Nekor and ruled it for more than three hundred years. Located beside the river Nekor, east of al-Husaima (al-Hoceima), it prospered through trade and commerce.
According to Rëfian tradition, à ÂÃÂlih ibn Mansà «r, ancestor of the à ÂÃÂlihids, established himself at TamsÃÂmÃÂn on the coast, where he converted the local Berber groups, the GhumÃÂra and the à ÂanhÃÂdja, to Islam. The new converts soon became apostate and unseated à ÂÃÂlih, and took as their leader a certain DÃÂwà «d al-Rundë al-Nafzë. à ÂÃÂlih was nonetheless restored to the throne and upon his death, his son al-Mu'taà Âim succeeded him. Later, his grandson Sa'id ibn Idris ibn à ÂÃÂlih founded in 760 or 761 the town of Nekor to serve as capital of the small state. The Madinat al-Nakur was situated on the banks of the river Nekor in an alluvial valley of the Rëf Mountains, 25 km inland from the Mediterranean coast. Under Indrisid rule it controlled productive agricultural territory that reached the coastal plain near modern-day al-Hoceima. The city flourished as it was on established trade routes and served as an entrepôt for goods shipped from Fes and SijilmÃÂsa in the south of the Rëf.
In 859, a major long-distance Viking expedition set out for Spain. They tried to land at Galicia and were driven off. Then they sailed down the west coast of the peninsula and up the river Guadalquivir to Ià ¡bëliya (Seville), where they burned the mosque but were repelled by a large Muslim force there before entering the Mediterranean through the Straits of Gibraltar and burning the mosque at al-Jazërah (Algeciras), following which they headed south to Nekor, plundered the city for eight days, and defeated a Muslim force that attempted to stop them.
Nekor was surrounded by a wall of coarse brick that also enclosed gardens and pomegranate and pear orchards. The city had many markets and shops, as well as baths, a large mosque, and an oratory (muá¹£allÃÂ). According to the historian Ahmed Tahiri it contains the oldest urban structure dating from the medieval period in the west of the Maghreb, built with the earliest Islamic construction methods. He considers the Viking invasion of 859 (Tahiri says 858) and the sacking of Nekor as a demarcation line in its urban evolution, and that afterwards, urban and rural architecture in the area became more defensive in orientation. The rivalry between the FÃ¤à £imid and the Umayyad Caliphates spurred the development of a new architectural layout in the city.
FÃ¤à £imid troops sacked the city twice, in 917 and in 934. According to J.D. Latham, 'Abd al-Rahman III, the Umayyad Caliph of Qurá¹Âuba (Córdoba), had observed with growing concern the increasing prestige and power of the FÃ¤à £imids in the Rëf, this region perilously close to al-Andalus. In 927 he began his policy of defensive expansion by occupying Malëlya (Melilla) and by 928-929, he opened negotiations with the Idrësids. In retaliation Mà «sàibn Abi'l-Afiya attacked and vanquished the Umayyad's vassal, al-Mu'ayyad, the à ÂÃÂlihid (à ÂÃÂlià Âid) ruler of Nakà «r, situated between Malëlya (Melilla) and Tiá¹ÂwÃÂn (Tetuan). The troops of Mà «sÃÂ, a Berber chieftain of the Miknasa tribe besieged, sacked, and burned Nekor in 931. With a fleet of forty vessels, the Umayyads launched a naval assault from Ceuta against Nekor and its port, al-Mazamma, and attacked Nekor, devastating the city which was garrisoned by three thousand men.
The relationship between the ruling family of the à ÂÃÂlihid (à ÂÃÂlià Âid) Emirate of Nekor and the local Berber tribal structure made it a predominantly Berber state, one aligned with the Umayyads of al-Andalus. The Umayyad Caliph al-Walid I had obtained the territory through iqá¹ÂÃÂÿ, the Isamic practice of tax farming. His son 'Abd al-Malik bestowed the region of Nekor as a gift to the Banà « à ÂÃÂlih ibn Mansà «r. The family settled there and intermarried with the local population of Berbers, who came to acknowledge them as their emirs.
According to the Arab Andalusi geographer al-Bakrë, à ÂÃÂlih ibn Mansà «r was renowned for converting the Berber tribes of northern Africa to Islam. All the Arab chroniclers credit à ÂÃÂlih ibn Mansà «r and the dynasty he founded with the Islamization of the Rëf. His grandson Sa'id ibn Idris ibn à ÂÃÂlih ibn Mansà «r built the city of Nekor in 760 or 761 to serve as the capital of the small state. He died after reigning over it for thirty-seven years. Emir Sa'id ibn Idris had ten sons. The third one, à ÂÃÂlih ibn Sa'id, assumed rule of the emirate upon his father's death. According to the narrative of al-Bakrë, à ÂÃÂlih's reign was filled with conflicts and wars with his brothers. He imprisoned his brother Idris and had him executed. à ÂÃÂlih ruled for twenty-eight years. When he died his youngest son, Sa'id ibn à ÂÃÂlih, was elected emir. The bond between the Emirate of Nekor and the Umayyads was strengthened by the fact that the Banà « à ÂÃÂlih professed the same Islamic creed as the Umayyad caliphs, that of the Maliki school.
Al-Bakrë says several ports of the Moroccan Rëf in the Emirate of Nekor â including Badia, Buquya, and BÃÂlish, the port of the á¹¢anhÃÂja (AáºÂnag) Berber confederation â were controlled by Berber tribes. These coastal communities developed with mixed populations of Berber, Arab, and Andalusi (converted or Mozarab) descent. The Berbers were taxed by the à ÂÃÂlià Âid emirs, and paid their taxes with the income they earned by exploiting marine resources on the coast and consequently controlling its maritime activity.
The à ÂÃÂlihids ruled over Nakur and the Berber tribes around it until about 1015, when Ya'la ibn al-Fatuh of the Azdaja tribe, now extinct, gained control of the emirate. His descendants defended the city and maintained their rule until the city was destroyed in 1080âÂÂ1081 for the fourth and last time by the Almoravid leader Yà «suf ibn TÃÂshfën. With the destruction of the city by the Almoravids, the iqta' or fief of Nakur, created in 710 for à ÂÃÂlih ibn Mansà «r by al-Walëd ibn ÿAbd al-Malik, caliph of the Umayyad Caliphate, ceased to exist.