KABUL — When a suicide bomber killed at least 30 people Wednesday near the majestic Sakhi shrine in west Kabul, where worshipers had gathered to mark the Persian new year, it was the latest in a fast-growing list of insurgent attacks that have targeted the capital’s Shiite, largely ethnic Hazara community in the past two years.

Both Islamic State and Taliban extremists have claimed more than a dozen attacks on mosques, shrines, schools and public rallies in the capital since 2016 — often during religious holidays or services — in an apparent attempt to sow divisions between Afghanistan’s majority Sunni Muslims and minority Shiite Hazaras.

Nationwide, insurgent attacks on Shiite and Hazara targets have claimed more than 300 lives and left more than 700 people wounded in the past two years. Most have been claimed by or are believed to have been carried out by the Islamic State.

Wednesday’s attack, which wounded more than 60 people, was the second Islamic State-claimed assault on the Sakhi shrine. In October 2016, gunmen wearing Afghan security uniforms stormed the site, which was filled with worshipers for the Shiite day of mourning known as Ashura. They killed 17 people and battled police for several hours.

The latest assault came less than two weeks after a suicide attacker on foot detonated explosives outside a large public gathering in the same area of Kabul, killing nine. The outdoor event was being held to commemorate a Shiite Hazara leader, Abdul Ali Mazari, who was killed by the Taliban in 1995.

It also followed an attempted suicide attack Monday in an education center in nearby Dasht-e-Barchi. Officials said a man wearing a suicide vest entered a large classroom full of students, tried to detonate his explosives and then threw a grenade that wounded six. 

While Hazara and Shiite leaders insist that they will not be intimidated and do not blame their plight on Sunni Afghans, the rising violence has taken a toll on the community’s nerves. It has also triggered rising frustration with the government of President Ashraf Ghani, which last year allowed local men to arm and patrol Shiite worship places in Kabul, a tacit admission that it could not protect them.

“We are walking on blood on every street,” said Jawed Kazemi, 60, a resident passing the site of Wednesday’s blast between the shrine and the Kabul University campus. Shoes, sandals and bits of human flesh were strewn on the ground nearby. He pointed to red stains on the road.

“This is our life,” Kazemi said angrily. “Poor people are dying. Why doesn’t Ghani order terrorists to be hanged?”

Emotions were also high after the March 10 suicide attack on the ceremony for Mazari, a former militia leader. One of the victims was Mohammad Zaki Yawari, 16, a high school student. His friends carried his body on their shoulders, wrapped in a white shroud, up a hillside graveyard the next day, then shoveled dirt into his grave.

“It is difficult to be a Hazara these days,” said Feraidon Hakimi, 19, one of the mourners, who had searched for him after the blast and found his body in a hospital morgue, lacerated by shrapnel. “Without doubt, we suffer more than anyone.”

Hazaras make up about 20 percent of Afghans and are almost all Shiites. They have been persecuted for generations, driven from their lands and relegated to menial jobs. After the Taliban were overthrown in 2001, they began to flourish in democracy, entering politics and rallying for their rights.

Now, the widening violence of the Islamic State, which views all Shiites as apostates, may be threatening that progress. Hazaras tend to be socially and politically liberal, which is also antithetical to hard-line Sunni militants. In its first-known attack on the group, the Islamic State bombed a peaceful protest by Hazara activists in Kabul in July 2016, killing more than 80 people. Since then, the pace of its attacks has increased. 

The Islamic State claims it is targeting Hazaras because they have been recruited to fight by the governments of Iran and Syria. In a propaganda video released last week, the group invited fighters who cannot go to Syria and Iraq to join them in Pakistan and Afghanistan, according to news reports. 

“Enemies want to take advantage of a sectarian war,” said Raihana Azad, a Hazara legislator from Kabul. “But ordinary Afghans live together peacefully.”

The spirit of Nowruz, the beginning of spring, is celebrated by Afghan Sunnis, too. Wednesday was a national holiday, with all Afghans off from work and school.

“Today’s egregious attack runs counter to the meaning of Nowruz, a time of renewal and celebration, and a time for promoting the values of peace and solidarity,” Tadamichi Yamamoto, the head of the U.N. mission in Afghanistan, said in a statement. But the quickening pace of attacks has unnerved some.

“It is dangerous for Afghanistan,” said Bashir Ahmad Ramazani, 30, a car mechanic whose shop was damaged in the Dasht-e-Barchi blast. “First, they target Hazaras, and then they go after Sunnis.”  

Constable reported from Islamabad. Sayed Salahuddin contributed to this report from Kabul.