Iranian supreme leader Ayatollah Ali Khamenei greets Hamas premier Ismail Haniya during a meeting in Tehran in February. Hamas, the militant Islamist group that rules Gaza, has distanced itself from Syria, raising questions about its ties to Iran. (AFP/Getty Images)

Political expression in this seaside strip is firmly regulated by the ruling Islamist militant group Hamas, and the authorities recently approved a robust street rally against an unlikely target: the government in Syria, long Hamas’s benefactor and host.

The demonstration, as well as Hamas leaders’ statements in support of Syrian protesters and the abandonment of their Damascus offices, was an indicator of the Gaza-based movement’s stark break with Syria — and of the rapidly shifting partnerships of a changing Middle East.

Although Hamas could once comfortably ally itself with fellow Sunni powers while at the same time receiving aid and hospitality from Shiite forces in Syria and Iran, the region’s growing sectarian divide means the group is likely to have to pick sides.

It might seem an easy choice. Sunni Islamic political movements are awakening across the region, and Hamas’s parent organization, the Muslim Brotherhood, is ascendant in next-door Egypt. Yet the power and policies of those forces are still evolving, making a wholesale split from Iran, a Syria ally and Hamas’s prime patron, risky for the group. Wavering, on the other hand, carries its own price: Hamas considers itself a populist movement, and polls indicate that Palestinians support the pro-democracy wave sweeping the region.

In interviews here, Hamas’s leaders depicted ties to the Syrian government of President Bashar al-Assad as a liability, and they distanced themselves from Iran. One senior leader, Salah al-Bardaweel, said Hamas fighters, long viewed as Iranian proxies, would hold fire in the event of an Israeli strike on Iran’s nuclear sites.

“If Israel strikes Iran, Iran will defend itself. Hamas doesn’t have any desire to be in a regional war,” Bardaweel said.

“Hamas cannot close its eyes to bloodshed like that taking place in Syria. It is Arab blood,” he said, calling the Syrian government’s crackdown “embarrassing.”

The path Hamas pursues, although far from certain, could sway its stumbling efforts to reconcile with the rival Palestinian faction Fatah, influence the moribund peace talks between Israelis and Palestinians and transform the dynamics of the isolated Gaza Strip, which has been under Israeli blockade since 2006. Hamas, which wrested control of the coastal enclave in a bloody battle with Fatah five years ago, is considered a terrorist organization by Israel and the United States.

Pragmatic considerations

Hamas’s position on the Syrian uprising, vague for much of the past year, became clear last month in Cairo, where Gaza’s Hamas Prime Minister Ismail Haniyeh stood with Muslim Brotherhood members and told a boisterous crowd that he supported the protesters. But in interviews in Gaza, Hamas officials still seemed eager to depict themselves as straddling two sides, insisting that their policy was neutral and in favor of the Syrian people, not against Assad. One key reason, several officials said, are the half-million Palestinian refugees who live in Syria and who might face repercussions for Hamas’s perceived disloyalty.

“We don’t want to repeat Yasser Arafat’s experience with Iraq and Kuwait,” said Hamas lawmaker Ismail al-Ashqar, referring to Kuwait’s 1991 expulsion of nearly 450,000 Palestinians after Arafat, the late Palestinian leader, sided with Iraq in the wake of its invasion of Kuwait.

Hamas’s dealings with Iran remain opaque. For now, Hamas leaders said, the group has no intention of reviewing its ties with Tehran and continues to receive funding from it. The officials insisted that they are not dependent on it — in part, Bardaweel said, because the funding has steadily decreased over the past three years.

Israel, which Hamas pledges to destroy in its official charter, remains deeply skeptical about the group’s intentions. Prime Minister Benjamin Netanyahu has warned that the revolutions of the Arab Spring would usher in anti-democratic Islamists who are hostile to Israel. An Israeli military official who spoke on the condition of anonymity said Hamas continues to stockpile weapons smuggled in from Libya and Egypt as well as longer-range missiles provided by Iran.

Egypt, the official said, would not be a moderating influence for Hamas, but rather “a safe house.”

The Muslim Brotherhood was banned under now-deposed Egyptian President Hosni Mubarak, and for years Hamas aligned itself with an anti-Israel bloc that spanned from Gaza to Iran and included Hezbollah, the Shiite Lebanese militia and political party.

But the Syrian crackdown on popular protests has forced Hamas’s external leadership in Damascus to seek a new base, Hamas officials in Gaza said. Egypt, which has a long-standing peace treaty with Israel, is said to be one candidate. So is Qatar, a Sunni Persian Gulf state and U.S. ally that is pushing a Hamas-Fatah accord and could compensate for any lost Iranian funding, analysts said.

“When the Assad regime falls, Hezbollah will become weak, as will Iran. And Hamas is a pragmatic movement, so they have already taken steps toward the Sunni coalition,” said Ibrahim Ibrach, a political science professor at al-Azhar University in Gaza, who said he thinks Hamas would be unlikely to react if Israel strikes Iran’s nuclear sites.

Power struggle

But Hamas’s posture may yet be determined by an unusually public power struggle between its Gaza-based and exiled leadership, Palestinian officials and analysts said.

Exiled leader Khaled Meshal, they said, believes that the Arab revolutions will empower a moderate political Islam and that new leaders in those nations will be too consumed with consolidating their domestic positions to adopt confrontational stances against Israel and the West.

Those considerations influenced Meshal’s decision to agree last month to what Hamas officials said was a Qatari demand that Fatah leader Mahmoud Abbas be named prime minister of a temporary Palestinian unity government. Several Gaza-based Hamas officials made little secret of their anger at the move, though they ultimately approved it.

The Gaza-based leadership thinks that a more hard-line Islamism could prevail in the region, giving Hamas little incentive to amend its policies now, analysts said.

What’s more, Hamas officials in Gaza said, the Arab Spring has boosted the freedom of movement — and the fundraising potential — of the Gaza leadership. Egypt opened a border crossing to some Gaza residents last year, and Haniyeh has been courting allies recently during his first trips outside the strip since 2007. In addition to Egypt, he has visited Persian Gulf nations and Iran.

“We can gain the fruits of these revolutions without interference,” said Mahmoud Zahar, a senior Hamas leader. In the past, he said, “many countries refused to accept leaders of Hamas. Now they are changing their attitudes.”