Unpaid teachers shut down thousands of schools across the West Bank and Gaza Strip on Saturday, the first day of the school year, in a major challenge to the embattled Hamas government.

The teachers' strike was observed widely both in the West Bank and Gaza, Hamas' stronghold. In the coastal strip, hundreds of Hamas militiamen patrolled school areas, unsuccessfully trying to persuade teachers, students and administrators who showed up at school to remain.

In the West Bank, activists from the rival Fatah party stood in front of schools, urging teachers and students to comply with the strike call, at times shooting in the air.

Teachers launched the open-ended walkout because the Hamas government -- impoverished by tough international sanctions meant to pressure it to recognize Israel -- hasn't paid them or 130,000 other government employees since taking office in March.

The strike was widely viewed as a tactic by Fatah, led by the moderate Palestinian President Mahmoud Abbas, to pressure Hamas to join with it in a so-called national unity government that would recognize Israel and renew peace talks.

Hamas has balked at participating in such a government, even though that would end the international boycott, which has cost the Palestinian Authority hundreds of millions of dollars in withheld payments from foreign donors and Israel.

The 37,000 striking teachers were to be joined by the civil servant and health workers unions, putting a total of 80,000 workers on strike. Garbage collectors in Gaza City walked off the job earlier this week, and the mountains of trash have left a rancid stench in the air.

Confused parents and students arrived at schools, unsure whether teachers were going to heed the strike call.

"The Hamas government is in a very bad position now," said Awwad Barghouti, who brought his son Saed to the El-Bireh secondary school near the West Bank town of Ramallah, only to find it closed. "It is at a crossroads. Either it concedes to the international community or it quits. I think the only way out is a national unity government."

Schooling is a major issue for Palestinians, and the closure of schools could decide the Hamas government's fate, political analyst Hani al-Masri said ahead of the walkout.

More than 1.1 million children are enrolled in nearly 2,400 schools in the West Bank and Gaza, according to the Education Ministry. About 800,000 attend 1,824 state-run schools, and the remainder study at private or U.N. schools, which operated on Saturday.

The Palestinians "have nothing but education," al-Masri said. "This strike will be a strong card with which to pressure the government. If it works, it will shorten its life. But if it fails, the life of the government will be prolonged."

A Palestinian Authority official said the government would issue a statement on the walkout later in the day.

Hamas Radio repeatedly broadcast that the strike had failed in the West Bank and central Gaza.

But compliance was widespread in major West Bank cities, though some teachers taught high school seniors, reluctant to disrupt their critical final year. And students who had showed up at central Gaza schools left shortly after arriving.

At a news conference in Ramallah, the head of the civil service union, Bassam Zakarneh, reported that 85-90 percent of the teachers were on strike, as were employees of all other government institutions, except police, utilities and state-run broadcasters.

"We are not going to end our strike until the government responds to our demands," Zakarneh said.

He said the government had not approached the union about talks.

In the West Bank town of Tulkarem, hundreds of armed Palestinian policemen fanned out in the streets to prevent clashes between protesting Hamas and Fatah supporters. More than 500 Hamas loyalists marched to the Ministry of Education building to demand that schools be opened.

Fatah gunmen in Tulkarem wrested building keys from janitors in several schools, but unarmed Hamas supporters punched out locks with hammers and opened school doors by force. Classes were held briefly, until teachers and students joined the protests held in the town.

In Gaza, and in Hamas strongholds in the West Bank like Hebron, many teachers opposed the strike, but complied with it because they were outnumbered by colleagues loyal to Fatah who were hired during that party's decade-long rule of the Palestinian Authority.

Teachers "have the right to demand good living conditions, but we also want to study," said Fadi al-Asali, 15, a student at the Khalil al-Wazir school in Gaza City. "I am going back home, and I hope this strike will be over soon because the losers are the Palestinians."

Principals loyal to Fatah locked all the classrooms in some Gaza schools to ensure compliance with the walkout. Some schoolyards were empty, and in others, hundreds of students milled around, unclear whether school would eventually open, or waiting for their parents to take them back home.

Fathi Samad, a Hamas supporter, lashed out against the walkout that left his 7-year-old daughter, Rawan, idle on the first day of school. "They are doing the same thing the (Israeli) occupation used to do when they closed schools," Samad said outside the Khalil al-Wazir school.

But Amel Akkad, a mother of a student at the Kamal Jumblatt school in the West Bank town of Nablus, empathized with the striking teachers. "The teachers need to live too," she said. "How are they to teach when they know they have no money at home and no food at home?"

Saeb Erekat, an Abbas confidant, said he hoped the strike would "be a wakeup call for all Palestinians."

"The Palestinian people need a government with a program that will enable them to resume their normal relations with the international community," Erekat said.