In 1820 the Ottoman Empire conquered most of Sudan from its base in Egypt. The rule was characterised by harsh taxes and numerous attempts to supress the slave trade in the region. By 1881 the country was ready for change. Muhammad Ahmed emerged as rebel leader and self-styled el-Mahdi (Guided One) and in 1885 his forces famously defeated the British Governor-General Charles Gordon at Khartoum. As part of their reforms for the country the Mahdi, and his successor the Khalifa, demanded that all Christians and the few Jews living in the country convert to Islam. These converts later became known as the Masalma.

In 1898, thirteen years after the Masalma laws were passed, British forces entered Sudan and the country became an Anglo-Egyptian Condominium. The laws enforcing Islam were revoked and most of the Masalma, including 36 Jews, returned to their previous faiths. It is unknown how many Jewish families were amongst the Masalma, but the descendants of those who decided to remain Muslim, and of others who continued to practice a form of secret Judaism, are still living in Sudan today.

As the invading British Army advanced it built a railway and once the country was under colonial rule this railway became key for trade and travel into and out of Khartoum. Whilst the journey to Egypt had previously been long and arduous, it could now be made in less than two days and Sudan became an attractive prospect for merchants wishing to make their fortune. From 1900 Jews from all over the Middle East and North Africa began to arrive in Sudan via Cairo and settle along the Nile in the four towns of Khartoum, Khartoum North, Omdurman and Wad Medani. Predominantly small time merchants of textiles, silks and gum, their businesses soon began to flourish.