They were convicted of killing soldiers, carrying out assassinations, and destroying military vehicles.
It was the first mass execution in the country since six jihadists were hanged in 2015.
Sinai has in recent years been beset by an insurgency, with jihadist groups including so-called Islamic State (IS) attacking targets including army, police and judges.
Last week, IS blew up a grounded helicopter with an anti-tank missile at a North Sinai airport, killing an army officer and wounding two others.
And in November, suspected IS militants carried out a devastating bomb and gun attack on a mosque in North Sinai that killed more than 250 people.
In the wake of that attack, President Abdul Fattah al-Sisi gave the military a three-month deadline to quell the unrest in Sinai, instructing it to use "brute force".
More about: #Egypt