Hamas denounced the move, which it said "serves the (Israeli) occupation."
Egyptian officials have accused Hamas of plotting with deposed Islamist president Mohamed Morsi and his Muslim Brotherhood movement to carry out "terror attacks" in the country.
Several Hamas militants have been named among scores of defendants on trial with Morsi for organising jailbreaks and attacking police stations during the 2011 revolt that toppled strongman Hosni Mubarak.
In a separate espionage trial, Morsi and 35 other defendants are accused of conspiring with foreign powers, including Sunni Hamas and Shiite Iran, to destabilise Egypt.
Also Read
Amnesty International says more than 1,400 people have been killed in street clashes, mostly Islamist supporters of Morsi, since his overthrow.
Senior Hamas official Bassem Naim told AFP the court's decision was "an attempt to besiege the resistance, and serves the Israeli occupation."
Egyptian troops have destroyed hundreds of smuggling tunnels under the border with Gaza used to supply the Palestinian enclave with fuel and construction materials due to Israeli restrictions.