Denmark, Great Britain, the United States, and France all abolished the slave trade between 1803 and 1814. This had to do with the result of Enlightenment ideas in Europe, and the related French Revolution in France in the final decades of the 18th century.
Furthermore, Article I, section 1, clause I, of the U.S. Constitution states that slavery couldn’t be banned before 1808 (most likely to appease the states required to ratify it). So, as early as 1789, the slave trade (not slavery as an institution itself) had a supposed expiration date.
Finally, there was a revolution in Haiti in 1791, in which the local whites battled with slaves, inspired by the French Revolution. The slaves outnumbered whites on the island, who eventually controlled it.
As for the effects in Africa, the slave trade stifled the development of a local economy while it existed, but its end allowed for a local economy to emerge. Exports included things like palm oil, peanuts, and vegetable oil. The slave trade, while it existed, allowed for the emergence of a religious aristocracy and biracial elite who profited from the trade. However, the end of the trade actually strengthened slavery in Africa (wherein slaves were used for fieldwork more than domestic service). Unfortunately, many African kingdoms fell (such as the Yoruba), while others (such as the Asante) survived this tumultuous period. In general, local commerce became more active in Africa after the end of the slave trade, and wealthy merchants emerged who were native to the region.