The Hague-based court was asked late last year by the UN General Assembly to determine Israel’s legal obligations after the country passed laws effectively banning the agency from operating there.
The International Court of Justice (ICJ) said on Wednesday that Israel must allow the UN aid agency in Gaza, UNRWA, to provide humanitarian assistance to the Palestinian territory.
The court, based in The Hague, was asked last year by the UN General Assembly to determine Israel's legal obligations after the country effectively banned the agency, the main provider of aid to the enclave, from operating there.
Israel "is under the obligation to agree to and facilitate relief schemes provided by the United Nations and its entities, including UNRWA," said ICJ President Yuji Iwasawa.
The advisory opinion from the World Court comes as a fragile US-brokered ceasefire in Gaza, which took effect on 10 October, continues to hold, though is threatened by continued Israeli aggression, which according to local health officials, has killed at least 88 Palestinians and injured more than 300 others.
Israel has denied that it has violated international law, saying the court's proceedings are biased. The country has refused to attend hearings in The Hague since April. Israel has also provided a 38-page written submission for the court to consider.
In a written statement, the Israeli Foreign Ministry rejected the opinion and said Israel "fully upholds its obligations under International Law."
"(We) Will not cooperate with an organisation that is infested with terror activities," It added, in a reference to UNRWA.
UN Secretary-General António Guterres has called the ruling "an important decision" and said he hoped that Israel will abide by it.
"This decision comes at a moment in which we are doing everything we can to boost our humanitarian aid in Gaza," Guterres told The Associated Press.
"So the impact of this decision is decisive in order for us to be able to do it to the level that is necessary for the tragic situation in which the people of Gaza still is."
UNRWA has been effectively banned from the territory since January. It has faced criticism from Israeli Prime Minister Benjamin Netanyahu and his far-right allies, like Finance Minister Bezalel Smotrich and National Security Minister Itamar Ben-Gvir, who say the UN agency is deeply infiltrated by Hamas.
UNRWA rejects that claim, and the ICJ found that Israel hadn't "substantiated the allegations," Iwasawa said.
The court also held that the population of the Gaza Strip had been "inadequately supplied," and that Israel was required to ensure "the basic needs of the local population" are met.
Representatives of the Palestinians applauded the decision. Palestinian Ambassador to the Netherlands Ammar Hijazi said it was "clear, unequivocal and conclusive" and left Israel with "no pretext, no context, no excuse" to ban UNRWA.
In an advisory opinion last year, the court said that Israel's presence in the occupied Palestinian territories is unlawful and called on it to end, and for settlement construction to stop immediately. That ruling fuelled moves for unilateral recognition of a Palestinian state.
Israel condemned the decision, saying it failed to address the country's security concerns.
Two decades ago, the court ruled that Israel's West Bank separation barrier was "contrary to international law." Israel boycotted those proceedings, saying they were politically motivated.
Advisory opinions carry significant legal weight, but are described as "nonbinding" as there are no direct penalties for ignoring them.
Wednesday's opinion is separate from the ongoing proceedings initiated by South Africa, accusing Israel of committing genocide in Gaza. Israel rejects South Africa's claim and accuses it of providing political cover for Hamas.