The Banu al-Khazraj (Arabic: بنو الخزرج Arabic pronunciation: [ˈbɛ.nʊl.ˈxɑz.ɾɑd͡ʒ]) is one of the tribes of Arabia since Muhammad's era. The Banu al-Khazraj are renowned for their generosity and hospitality.
Abu Muhammad Al-Hasan Ibn Ahmad Al-Hamdani mentioned that the Banu Khazraj and the Banu Aws settled the area of Yathrib around the 2nd century AD as part of the Pre-Islamic Exodus of Yemen because of the Great Marib Dam damage.
However, all sources agree that the Banu Khazraj and Banu Aws became hostile to each other.
During the battle, the Banu Nadir and the Banu Qurayza fought on the side of the Banu Aws, and the Banu Qaynuqa were allied with the Banu Khazraj. The latter were defeated after a long and desperate battle.
The Nusaybah clan family of Jerusalem, Custodians of the Church of the Holy Sepulchre, are descendants of Banu Khazraj. They arrived in Jerusalem with the 7th-century Islamic conquest.
On 624 Muhammad ordered the assassination of Ka'b ibn al-Ashraf. According to Ibn Ishaq, Muhammad ordered his followers to kill Ka'b because he "had gone to Mecca after Badr and inveighed against Muhammad. He also composed verses in which he bewailed the victims of Quraysh who had been killed at Badr. Shortly afterwards he returned to Medina and composed amatory verses of an insulting nature about the Muslim women". This killing was carried out by the Banu Aus 
When men of the Banu Aus tribe murdered Ka'b ibn al-Ashraf, some Khazraj tribesman including Abdallah ibn Unais went to Muhammad and received permission to put to death the person responsible for the killing of Sallam ibn Abu al-Huqayq, who was killed during the Expedition of 'Abdullah ibn 'Atik.
Sallam ibn Abu al-Huqayq (Abu Rafi) was a Jew, who helped the troops of the Confederates and provided them with a lot of wealth and supplies, on the one hand  and used to mock Muhammad with his poetry, on the other. When the Muslims had settled their affair with Banu Quraiza; Al-Khazraj tribe, a rival of Al-Aws, asked for Muhammad's permission to kill him (which Muhammad accepted) in order to merit a virtue equal to that of Al-Aws who had killed Ka'b ibn al-Ashraf.
In 1228, Ibn al-Ahmar gathered the remains of the Muslim population cornered in Granada and established al-Mamlika al-Nasria derived from the Ansar of Medina whom the Nasrids trace their lineage to. With the Reconquista in full swing after the conquest of Cordoba in 1236, the Nasrids aligned themselves with Ferdinand III of Castile, officially becoming a tributary state in 1238. The state officially becoming the Kingdom of Granada in 1238. The Nasrids had to turn their backs against the Muslims of Cordoba and Seville in order to survive the reconquest.
Initially the kingdom of Granada linked the commercial routes from Europe with those of the Maghreb. The territory constantly shrank, however, and by 1492, Granada controlled only a small territory on the Mediterranean coast. Arabic was the official language, and was the mother tongue of the majority of the population.
Granada was held as a vassal to Castille for many decades, and provided trade links with the Muslim world, particularly the gold trade with the sub-saharan areas south of Africa. The Nasrids also provided troops for Castille while the kingdom was also a source of mercenary fighters from North African Zenata tribes. However, Portugal discovered direct the African trade routes by sailing around the coast of West Africa. Thus Granada became less and less important for Castille and with the unification of Castille and Aragon in 1479, those kingdoms set their sights on conquering Granada and Navarre.
On January 2, 1492, the last Muslim leader, Muhammad XII, known as Boabdil to the Spanish, surrendered complete control of Granada, to Ferdinand and Isabella, Los Reyes Católicos ("The Catholic Monarchs"), after the city was besieged.
See Nasrid dynasty for a full list of the Nasrid rulers of Granada. The most prominent members of the dynasty were: