Seven people have been shot dead at a synagogue in East Jerusalem, the most killed in an attack of this kind for years. At least three more people were injured.
The incident happened in the city's Neve Yaakov neighbourhood at about 20:15 local time (18:15 GMT).
Police described the attacker as a "terrorist" and said he had been "neutralised".
Local media identified him as a Palestinian man from East Jerusalem.
Speaking at the scene, Israeli police commissioner Kobi Shabtai called it "one of the worst attacks we have encountered in recent years".
Israeli worshippers had gathered for prayers at the start of the Jewish Sabbath in a synagogue in the Jewish settlement and were leaving when the gunman opened fire. Police say that officers then shot him dead.
Forensic teams are investigating a white car that appears to have been driven by the gunman.
Palestinian militant groups praised the attack, but did not say one of their members was responsible.
The attack was celebrated by Palestinians in the West Bank and the Gaza Strip with rallies and the handing out of sweets.
The attack happened on Holocaust Memorial Day, which commemorates the six million Jews and other victims who were killed in the Holocaust by the Nazi regime in Germany.
"To attack worshippers at a synagogue on Holocaust Memorial Day, and during Shabbat, is horrific. We stand with our Israeli friends," British Foreign Secretary James Cleverly wrote on Twitter.
US Secretary of State Antony Blinken said: "The United States condemns in the strongest terms the horrific terrorist attack."
President Joe Biden talked with Israeli Prime Minister Benjamin Netanyahu and offered all "appropriate means of support", the White House said.
Shortly after the incident, Mr Netanyahu visited the site, as did the controversial far-right National Security Minister, Itamar Ben-Gvir.
Mr Ben-Gvir promised to bring safety back to Israel's streets but there is rising anger that he has not yet done so, says the BBC's Yolande Knell in Jerusalem.
Tensions have been high since nine Palestinians – both militants and civilians – were killed during an Israeli military raid in Jenin in the occupied West Bank on Thursday.
This was followed by rocket fire into Israel from Gaza, to which Israel responded with air strikes.
United Nations Secretary-General Antonio Guterres is "deeply worried about the current escalation of violence in Israel and the occupied Palestinian territory", a spokesperson said.
"This is the moment to exercise utmost restraint," said Stephane Dujarric.
Israel has occupied East Jerusalem since the 1967 Middle East war and considers the entire city its capital, though this is not recognised by the vast majority of the international community.
Palestinians claim East Jerusalem as the future capital of a hoped-for independent state.