In the 7th century, early Muslims from Mecca, at least companions of the Islamic prophet Muhammad, sought refuge from Qurayshi persecution by travelling to the kingdom, a journey known in Islamic history as the First Hijrah. They reportedly built the first African mosque, that is the Mosque of the Companions, Massawa.