The Sinai campaign was fought by a principally British and dominion force, against Turkish forces operating from Palestine, for the security of the Suez Canal. There were only a small number of routes across the Sinai Peninsula from Palestine to Egypt that the Turks could take due to the arid terrain and the availability of wells, which restricted the main operations to within 60 kilometres of the Mediterranean coast.
The Turkish forces launched their first attack on the Suez Canal, Britain's vital link to the East and Australia, on 3 February 1915, having dragged heavy loads of pontoons and other bridging equipment over 160 km of desert. The attack was poorly coordinated and easily repulsed, and the Turkish forces were driven back into the Sinai desert. After this attack the British forces pushed their defences out 10 km east of the canal. The Gallipoli campaign subsequently limited the resources available for the defence of the canal, but also deprived the Turks of the ability to mount a renewed offensive.
The end of the Gallipoli campaign in December 1915, dramatically altered the military situation on the Sinai peninsula. Turkey now had the troops available to launch a new drive on the canal, and the British sufficient troops to attempt to defend it in depth. Plans were formulated to establish a defensive line on the far side of the peninsula between El Arish and Kossaima. Initially, British troops were pushed out to Katia 40 km from the canal, but this outpost was destroyed by Turkish forces on 23 April 1916, heralding a new Turkish attempt to seize the Suez Canal.
The second Turkish advance on the canal began in mid-July 1916 and culminated in the battle of Romani on 4-5 August. Although outnumbering the British and dominion forces against them, the Turks were defeated and fell into a retreat, which, despite several dogged rearguard stands, carried them all the way back to their outposts on the Palestine frontier. The defences around Magdhaba were captured on 23 December, and those at Rafa on 9 January 1917. The last small garrisons of Turkish forces were defeated in February 1917, completing the Allied occupation of the Sinai peninsula, ensuring the security of the Suez canal, and opening up the Palestine front.