A 19-year-old Palestinian man has been killed in overnight violence with Israeli settlers in a flashpoint town in the occupied West Bank.
Dozens of settlers, including a far-right MP, had entered Huwara following a shooting attack on an Israeli family, in which nobody was hurt.
Israeli forces said they later killed the suspected Palestinian gunman.
Tensions have been running high in the northern West Bank approaching the end of the Jewish Sukkot holiday.
The Palestinian town of Huwara lies on the main road, Route 60, running through the north to south of the West Bank, which is used by Palestinians and Jewish settlers.
In recent months, it has seen a number of shootings on Israelis and revenge attacks by settlers who live nearby.
Early on Friday, the ultranationalist finance minister Bezalel Smotrich visited the town with settler leaders and a member of his political party, Zvi Sukkot, who was present during the previous night's events.
After Friday prayers in Huwara, a large crowd carrying Palestinian flags gathered for the funeral of Labib Dumeidi, the young Palestinian who was killed.
There were protests after the funeral, with Palestinian medics saying more than 50 people were injured in clashes with Israeli forces, including three by live gunfire.
Labib Dumeidi's relatives say that he was inside his home watching the previous night's violence when he was fatally shot in the chest. The Palestinian health ministry claims he was killed by a Jewish settler.
However, the Israeli military gave a different account, saying its soldiers shot a Palestinian who "threw a block at an Israeli vehicle".
Overnight, violence had spiralled after a group of Israelis, including Mr Sukkot, arrived in Huwara to set up a Sukkah - a temporary shelter that religious Jews put up for the Sukkot festival, which ends this weekend.
A video shared on social media shows that a large group of settlers, including the lawmaker, then held a Torah lesson in the middle of the road, which had been closed off by the Israeli army.
In later videos, Israelis and Palestinians can be seen throwing stones. Palestinian witnesses said that homes, shops and cars were vandalised by settlers.
The Israeli military says it used "riot dispersal means to defuse the confrontation". Some 60 Palestinians were given medical treatment, mostly for tear gas, according to the Palestinian Red Crescent.
The local mayor, Mueen al-Dumaidi, told the OceanNewsUK that some of the settlers were armed and that they had stayed in Huwara for at least five hours. He said that Palestinians "were defending their town".
Mr Dumaidi added that Huwara - which has been closed to Palestinians for hours at a time in the past week for what Israel says is security reasons - was enduring "a daily collective punishment by the army and the settlers".
On Thursday afternoon, dashcam footage showing a Palestinian man dressed in black firing at an Israeli car stuck in traffic in the town was widely shared in the Israeli media.
The driver escaped by swerving onto the opposite side of the road and speeding off. The Israeli military said its troops later tracked down and killed the suspected gunman.
Israeli media quoted the woman who had been targeted with her husband and baby as saying: "Thank God we escaped unscathed, my daughter is still sleeping in the car." She said her family had been returning to Jerusalem after visiting a settlement outpost.
Earlier on Thursday, two Palestinian gunmen and five Israeli military police officers were wounded in separate incidents in Tulkarm.
Meanwhile, at Joseph's Tomb in Nablus, explosive devices were detonated as an Israeli bus convoy passed, escorted by the Israeli military. There were no Israeli casualties but around 100 Palestinians were wounded in clashes with Israeli security forces, according to the Palestinian Red Crescent.
In the past year-and-a-half, there has been a surge in violence in the West Bank, which Israel has occupied since the 1967 Middle East War.
This has seen near-nightly Israeli military raids, an increase in Palestinian attacks on Israelis and a rise in Israeli settler violence against Palestinians and their property.
Settlements are seen as illegal under international law, but Israel disagrees. Several members of the current Israeli hardline government, including Mr Smotrich, are strong supporters of settlements.