Maher Abdel Wahid, the national general prosecutor who led a team of investigators to the scene, said he did not expect the toll to rise much beyond 373.
It was the worst train accident in Egypt in decades, according to Ahmed al-Sherif, director of the state-owned Egyptian Railway Authority.
"There has been nothing in the recent or distant past like this," he said at the scene. "I've been with the railway for 32 years and never seen or heard of an event of this size."
Egypt's Middle East New Agency said the cause of the fire was a burst gas cylinder using for cooking in the dining car. But al-Sherif said the cause had not yet been determined. He said the third-class train had no dining car, but that passengers often brought gas cylinders and small stoves aboard despite regulations forbidding it.
Each car designed to hold about 150 passengers was crammed with twice that number, police said, which would have put more than 3,000 people aboard. Survivors said the train was so full that they were sitting on the floor. Al-Sherif put the number aboard lower, at about 1,200, but acknowledged even that figure meant the train was overcrowded.
Abdel Wahid said that if his 25 investigators and 45 coroners determined "there was any kind of negligence, and that's what we are looking into, the punishment will be severe."
President Hosni Mubarak was quoted by MENA in the Egyptian resort of Sharm el Sheik as expressing his "deepest regret and profound sorrow" to the families of the victims.
Al-Sherif said the train left Cairo on its 480-kilometer (300-mile) journey to Luxor about 11:30 (2130GMT) Tuesday night and the fire broke out about 1 a.m. Wednesday (2300GMT Tuesday). The train traveled in flames for four kilometers (2.5 miles) before finally stopping at Reqa al-Gharbiya, a village 95 kilometers (60 miles) south of Cairo. Al-Sherif it was not clear why the emergency brakes were not applied immediately.
The flames were put out hours later as the train sat in Reqa al-Gharbiya. Firefighters said high winds had hampered their efforts.
The fire appeared to have broken out in the fourth car, which was the most badly burned. Flames reached seven of the 11 cars before the fire was extinguished.
The Muslim Brotherhood, the banned fundamentalist movement that is Egypt's main opposition group, questioned how the fire could spread so quickly. Members of the group serving in parliament as nominal independents issued a statement calling for an investigation into the "gross negligence that led to this tragic incident. "
The Brotherhood has in the past won praise from ordinary Egyptians for its disaster relief efforts. The government, wary of the group's growing popularity, several years ago banned non-governmental organizations from providing emergency aid.
Mohammed Mersi, head of the Muslim Brotherhood faction in parliament, said the group would abide by the aid ban but study what else it could do to help.
Wednesday afternoon, a warning siren blared repeatedly in Reqa al-Gharbiya as workers wearing gloves and masks placed bodies charred and twisted by fire into ambulances. A firefighter said some of the corpses were under seats as if people had retreated there in hopes of finding safety.
Corpses had melded together in piles on the train. Among charred luggage collected nearby, a Bible, children's clothing and what appeared to be a wedding dress could be seen.
By the time Abdel Wahid, the prosecutor, said the final toll was unlikely to climb beyond 373, only one ambulance stood by.
Police said 65 people were being treated for injuries, most in the hospital in the nearest town, Ayyat, (20 kilometers) 12 miles to the north.
Said Fuad Amin, a 22-year-old construction worker, jumped from the burning train and was being treated for a broken hand and a suspected concussion in Ayyat.
He said the first signs of trouble on the packed train were shouts and screams that he attributed to a fight. Then he saw flames and people running, including a women whose clothes were on fire.
Amin ran, too, until he found a window broken open. He hesitated at first because the train was moving fast.
"I thought I was going to die anyway, so I jumped," he said.
Some jumpers weren't so lucky. Ambulance workers say 40 bodies were recovered from along the tracks.
Like many of the passengers, Amin was going to his home village for Eid al-Adha, or the "Feast of the Sacrifice," a four-day holiday that starts Friday. The holiday commemorating God's provision of a ram to substitute for the son Abraham is regarded as the most important feast in the Islamic calendar.
Mosques were opened to the rescued and villagers supplied blankets, food and hot drinks to the stranded passengers.
The rail line linking Cairo with southern Egypt was closed indefinitely.
Wednesday's fire was the deadliest train accident in years in a country where such tragedies are common.
The state-owned Egyptian Railway Authority has been plagued by overstaffing, old equipment and poor service. It relies on heavy state subsidies to operate some 1,300 trains every day, keeping fares low for the poor Egyptians who rely on the trains.
Prime Minister Atef Obeid, who went to the scene, defended the railway.
"All trains are in good shape and at the highest degree of efficiency and they are reviewed completely and regularly," the prime minister said.
Railway Director Al-Sherif said the train engulfed in fire Wednesday had no technical problems and was carrying fire extinguishers.