Ottoman Egypt was an administrative division of the Ottoman Empire after the conquest of Mamluk Egypt by the Ottomans in 1517. The Ottomans administered Egypt as a province (eyalet) of their empire (Ottoman Turkish: ایالت مصر, romanized: Eyālet-i Mıṣr). It remained formally an Ottoman province until 1914, though in practice it became increasingly autonomous during the 19th century and was under de facto British control from 1882.
Egypt always proved a difficult province for the Ottoman Sultans to control, due in part to the continuing power and influence of the Mamluks, the Egyptian military caste who had ruled the country for centuries. As such, Egypt remained semi-autonomous under the Mamluks until Napoleon Bonaparte's French forces invaded in 1798. After Anglo-Turkish forces expelled the French in 1801, Muhammad Ali Pasha, an Albanian military commander of the Ottoman army in Egypt, seized power in 1805, and established a quasi-independent state.