Trade was important to the growth of West African Sahelian Kingdoms in the postclassical period, 600-1450 CE. Three examples of centralized West African Kingdoms were (in chronological order) Ghana, Mali, and Songhai. Without a connection to trade networks throughout North Africa, these Kingdoms would not have been as successful.
Many elites in these kingdoms converted to Islam in order to benefit in trading with Muslim merchants and the Islamic world. From the mid 7th century until the mid 13th century, two Islamic Empires (the Umayyads and Abbasids) ruled over much of the Middle East, North Africa, and parts of Southern Spain. Travelers and traders in these regions, notably the Berber nomadic group, traded goods between West African kingdoms and the Islamic Empires. Mali, for example, profited immensely off of the gold and salt trade along the Trans-Saharan trade routes. Malian Kings, notably Mansa Musa, used these trade routes to make the Muslim pilgrimage to Mecca (the hajj) and they spread West African wealth, culture, and power along the way.
Other factors that led to the rise of West African Kingdoms was a need for centralized, powerful states. Previous groups existed in this region, like the Bantu, who were organized as a stateless society. Due to environmental and agricultural problems, the Bantu migrated South. In order to survive in the harsh desert environment of the Sahel and Sahara deserts, stronger, centralized Kingdoms that relied on trade popped up on rivers, like Timbuktu (the Malian capital) on the Niger River. Without a centralized empire, civilization would not have been as successful in West Africa.