CAIRO — The anniversary of Egypt’s 2011 uprising brought a violent display of the country’s furious divisions Saturday, as giant crowds danced at government-backed rallies and security forces crushed demonstrations by rival Islamists and some secular activists.
Clashes nationwide killed at least 29 protesters, health officials said. The starkly contrasting scenes reflect the three years of turmoil Egypt has faced since the Jan. 25, 2011 revolution began and ultimately toppled autocrat Hosni Mubarak, replacing him with a transitional military council.
Last summer’s millions-strong demonstrations against Mubarak’s elected successor, Islamist President Mohammed Morsi, led to a military coup removing him. And as Egypt looks forward to presidential elections later this year, many celebrating Saturday in the famed Tahrir Square demanded that army chief Abdel-Fattah el-Sissi run for president.
‘‘El-Sissi saved the nation. It was up in the air like this helicopter and he carried it to safety,’’ said Mervat Khalifa, 62, sitting on the sidewalk and waving to a helicopter overhead.
Military helicopters showered crowds in Tahrir with small flags and gift coupons to buy refrigerators, heaters, blankets, and home appliances. State-backed rallies also showcased prancing horses and traditional music for ecstatic crowds.
Morsi’s supporters used Saturday’s anniversary to build new momentum in their defiance of the military and its political transition plan, despite being hit by a crippling police crackdown and rising public resentment against his Muslim Brotherhood group.
‘‘Anger is bigger than all. Repression sparks revolutions. The burning of Egypt won’t last,’’ a statement issued by a Brotherhood-led coalition said.
The fiercest clashes raged in an eastern Cairo suburb, where Islamist supporters fought with security forces for hours in pitched street battles. Troops fired over the crowd to disperse protesters who threw gasoline bombs. Protesters set up a field hospital to aid the wounded.
Violence also was strong in the provinces. A car bomb exploded outside a security camp in the city of Suez, where gunmen clashed with police, witnesses said. Nine civilians were wounded in the bombing, authorities said.
In neighboring Ismailiya, protesters chanting ‘‘down with military rule’’ also battled security forces. In Alexandria, a female protester was shot and killed during clashes, officials said. Two protesters were killed in the southern city of Minya, security officials said.
The clashes in the eastern Cairo suburb of Alf Maskan were fiercest.
Protesters Mustafa Mohammed and Sami, who only gave his first name for fear of reprisals, said security personnel and rooftop snipers used live rounds against demonstrators. The gunfire struck a natural gas pipeline three times, Mohammed said.
Sami said protesters threw gasoline bombs in the clashes, which wounded hundreds. Two security officials in the area described the situation as tense and said at least six people were killed. The protesters put the figures at 24.
The clashes contrasted with scenes of celebration in Tahrir Square and other major squares in provincial capitals, where long queues of demonstrators lined up to enter the tightly secured areas through metal detectors.
Some celebrating wore paper masks with el-Sissi’s picture and their rallies showed a ferociously anti-Islamist tone.
Soldiers guarding Tahrir Square joined them in chanting: ‘‘The people want the execution of the Brotherhood.’’ A crowd beat a woman in a conservative headscarf and drove her away, believing she was a Brotherhood sympathizer.
Crowds also turned on journalists. More than a dozen were beaten by demonstrators or were detained by police for protection from angry crowds.
Demonstrators chased one Egyptian female journalist, mistakenly believing she worked for satellite news broadcaster Al-Jazeera — seen as pro-Brotherhood. They pulled her hair and tried to strangle her with a scarf until police took her into a building for protection.
Security forces also dispersed rallies by secular youth activists who led the 2011 anti-Mubarak uprising and who are critical of both the Islamists and the military.
A number of their most prominent figures have been detained for months or sentenced to prison amid a campaign to silence even secular voices of dissent.
One prominent activist, Nazly Hussein, was detained by police on the subway as she headed to join one rally downtown, said her mother, Ghada Shahbendar.
In its statement, the Brotherhood appealed to secular youth groups to unite with it in protests.
Secular youth groups, however, have shunned the Islamists, whom they equally accuse of undermining the 2011 uprising’s goals while in power.