There was no immediate claim of responsibility for the attack, in which at least nine people were wounded, but Egyptian security sources said police had arrested three suspected militants and were looking for two more.
The sources said all of those who died were inside the bus parked outside the Egyptian Museum at Tahrir Square, one of Cairo's busiest areas.
An Interior Ministry statement identified one gunman as Saber Farahat Abu el-Ela, who was put in a mental hospital after he fired on tourists at the Semiramis Intercontinental Hotel in Cairo four years go.
Ela's brother Mahmoud was also arrested after the attack, the statement said. Security sources said the third gunman was shot in the head and was in a critical condition. Security sources said one of the gunmen climbed aboard the bus, reported to be carrying 33 German tourists, and started spraying the interior with gunfire.
When he saw several tourists escaping through the rear exit, the gunman threw a petrol bomb inside. He then ran out and put a second bomb under the bus.
Other gunmen fired at three or more buses parked near the museum, security sources said.
Thousands of tourists visit the Egyptian Museum every day. The sprawling building houses more than 100,000 ancient relics, the most outstanding being the tomb and gold mask of Tutankhamun.
Security sources suspect the gunmen were Muslim militants who have been seeking to topple the government since 1992.
The attack was the first major militant operation in the capital since April 1996, when suspected militants shot dead 18 Greek tourists and wounded 14 outside a hotel.
It was one of the bloodiest attacks against the Egyptian tourism industry since militants began sporadically targeting tourists in 1992 as a way to damage the country's economy in their fight against the government.
Before yesterday, Muslim militants had killed 26 foreigners and wounded 73.
The German Foreign Minister, Klaus Kinkel, expressed horror at the bomb attack, saying it was the third disaster to hit Germans abroad this week.
"I learned with horror of the bomb attack on a tourist bus in Cairo in which there were many dead and injured, including Germans. It is the third disaster this week," Mr Kinkel said.
News of the Cairo bombing followed two air disasters within the last five days that killed 29 German soldiers and diplomats.
Five Germans died on Wednesday in a helicopter crash in Bosnia on a UN peacekeeping mission, and 24 were killed off the coast of south-west Africa on Saturday when their army transport crashed, possibly in a mid- air collision with a US military aircraft. Reuters