The protesters accused President Hosni Mubarak's regime of unleashing a force of paid thugs and plainclothes police to crush their unprecedented nine-day-old movement, a day after the 82-year-old president refused to step down. They showed off police ID badges they said were wrested from their attackers. Some government workers said their employers ordered them into the streets.
"I offer my apology for everything that happened yesterday because it's neither logical nor rational," Shafiq told state TV. "Everything that happened yesterday will be investigated so everyone knows who was behind it."
Complete Coverage: Anger in the Arab World
The public apology from a top government official was highly unusual. Shafiq called the attack a "blatant mistake" and promised to investigate "so everyone knows who was behind it."
Shafiq also said during a later news conference that the country needed time to heal and said he would be willing to go to Tahrir Square to meet with the protesters.
Meanwhile, Egyptian army tanks and soldiers moved to end violence between the two factions Thursday. Hours after automatic gunfire hit the anti-government protest camp at Tahrir Square, killing at least eight protesters, soldiers carrying rifles could be seen lining up between the two sides around 11 a.m. Several hundred other soldiers were moving toward the front line.
Four tanks cleared a highway overpass from where Mubarak supporters had hurled rocks and firebombs onto the protesters.
The Deadly Beating that Sparked Egypt Revolution
Is Egypt's Military for the People or President?
The pre-dawn firing escalated what appeared to be a well-orchestrated series of assaults on the demonstrators that began when Mubarak supporters charged into the square on horses and camels on Wednesday afternoon.
Anti-Mubarak demonstrators traded showers of rocks and other projectiles in a counter-assault that drove their assailants out of the square within hours. Anti-government protesters took army trucks and set up an ad-hoc front line on the northern edge of the square, near the famed Egyptian Museum. The two sides traded volleys of rocks and Molotov cocktails for much of the night, until sustained bursts of automatic gunfire and powerful single shots rained into the square starting at around 4 a.m. and continuing for more than two hours.
The anti-Mubarak movement has vowed to intensify protests to force him out by Friday.
The notion that the state may have coordinated violence against protesters, who had kept a peaceful vigil in Tahrir Square for five days, prompted a sharp rebuke from Washington, which has considered Egypt its most important Arab ally for decades, and sends it $1.5 billion a year in aid.
"If any of the violence is instigated by the government, it should stop immediately," said White House Press Secretary Robert Gibbs.
Egypt's Interior Ministry denied sending plainclothes policemen to join the crowds attacking protesters.
Mustafa el-Fiqqi, a senior official from the ruling National Democratic Party, told The Associated Press that businessmen connected to the ruling party were responsible for Wednesday's attacks on the protesters.
After years of tight state control, protesters emboldened by the uprising in Tunisia took to the streets of Cairo and other cities on Jan. 25 and mounted a once-unimaginable series of demonstrations across this nation of 80 million.
State TV said Vice President Omar Suleiman called "on the youth to heed the armed forces' call and return home to restore order." From the other side, senior anti-Mubarak figure Mohamed ElBaradei demanded the military "intervene immediately and decisively to stop this massacre."
U.S. Secretary of State Hillary Rodham Clinton spoke with Suleiman to condemn the violence and urge Egypt's government to hold those responsible for it accountable, State Department spokesman P.J. Crowley said.
The United States and European allies including Britain, France and Germany have been pressing Mubarak to begin a political transition immediately. Mubarak promised Tuesday not to run for re-election in September, named a new government and appointed a vice president for the first time, widely considered his designated successor.
A joint statement from five European leaders Tuesday said they are watching the unrest in Egypt with "utmost concern" and condemned "all those who use or encourage violence, which will only aggravate the political crisis in Egypt."
Egypt's Foreign Ministry spokesman, Hossam Zaki, said the government considered the calls unwelcome interference.
"It is very regrettable to find that countries such as the United States, Britain and France want to benefit from the current circumstances to achieve political goals and benefits," Zaki said.