More than 12 million Africans were forcibly transported across the Atlantic to work as slaves between 1515 and the mid-19th Century. Some two million of the enslaved men, women and children died on their way to the Americas.

The slave trade began after the Portuguese started their exploration of the West Coast of Africa. As the demand for slaves in Europe increased, the trade intensified as chiefs and traders engaged in warfare and raids which led to the capture and enslavement of many people. Much of the slave trade was focused on West Africa, and so many of those captured and sold into slavery during raids were Muslim.

Bilali Muhammad was one of those slaves who remained dedicated to his Islamic faith despite being enslaved in America. Born around 1770, Muhammad was a Fula, from the city of Timbo, in the Muslim empire of Fouta-Djallon, in what is now Guinea. He was a well-educated person before he was captured and sold into slavery. Historians say he spoke fluently the Fula language and Arabic and was well-versed in high-level Islamic studies, including Hadith, Shari’ah, and Tafsir.

It is not known how he was captured but what is known is that he was taken to an island plantation in the Caribbean where he was purchased in 1801 by Georgia politician and agriculturalist Thomas Spalding, who took Muhammad to a plantation he owned at Sapelo Island, off the coast of Georgia in the southern U.S.

While most slaves in the South had to work under harsh conditions and were not allowed to have proper clothing and shelter, Muhammad had certain freedoms on Spalding’s plantation. He and the other slaves on the Georgia politician plantation were not forced to work over six hours a day and those who were Muslims were allowed to practice their religion openly in an area dominated by Christians.

It is documented that Muhammad was even allowed to build a small mosque on the plantation, which was possibly the first mosque in North America.

And having received a high level of education, Muhammad was also allowed to handle much of the administration work of the plantation while taking care of the slaves. Spalding trusted Muhammad so much that he gave him control of the plantation along with weapons during the War of 1812 between the United States and the United Kingdom. Spalding left the plantation with his family during the war and asked Muhammad to be in charge of it while defending it from any attack. Muhammad did that, giving some of the weapons left with him to other Muslim slaves and others to defend the plantation during the attack. Spalding returned after the war to take back the plantation.

Still thanks to his education, Muhammad, in the 1820s, hand-wrote a 13-page text in Arabic and gifted it to a southern writer, Francis Robert Goulding, before he died in 1857. The document is now reported to be in the collection of the Hargrett Rare Book & Manuscript Library at the University of Georgia. In the 1820s when Americans came across the document, they found it difficult to work out what it was and even thought it was Muhammad’s diary.

Scholars including those from al-Azhar University in Egypt were called in to help and after some years, they realized that it was a copy of passages from a treatise on Islamic law in the Maliki madhab which was written by a Muslim scholar of fiqh, Ibn Abu Zayd al-Qairawani in Tunisia in the 900s, according to this report cited by Egypt Today.

“The Risala of Ibn Abu Zayd was a part of the West African law curriculum prevalent in Bilali’s homeland in the 1700s when he was a student. When he came to America as a slave, he was of course unable to bring any personal belongings with him, and thus his copy of the Risala was written entirely from memory decades after he learned it in West Africa,” the report adds.

Bilali’s document is therefore said to be the first book of Islamic jurisprudence (fiqh) ever written in the United States or the first Islamic text ever written in the U.S.