
The original inhabitants of Mauritania were the Bafour, presumably a Mande ethnic group, connected to the contemporary Arabized minor social group of Imraguen ("fishermen") on the Atlantic coast.
The territory of Mauritania was on the fringe of geographical knowledge of Libya in classical antiquity. Berber immigration took place from about the 3rd century. Mauritania takes its name from the ancient Berber kingdom and later Roman province of Mauretania, and thus ultimately from the Mauri people, even though the respective territories do not overlap, historical Mauritania being considerably further north than modern Mauritania.
The Muslim conquest of the Maghreb in the 7th and 8th centuries did not reach as far south, and Islam came to Mauritania only gradually, from about the 11th century, in the context of the wider Islamization of the Sudan and medieval Arab slave trade.