JERUSALEM — Israel’s parliament passed a contentious law late Monday that allows the state to seize land privately owned by Palestinians in the West Bank and grant the properties to Jewish settlements for their exclusive use.

The measure is designed to protect homes in Jewish settlements, built on private Palestinian property “in good faith or at the state’s instruction,” from possible court-ordered evacuation and demolition.

Thousands of homes in dozens of settlements and outposts may now be protected, at least temporarily. The bill is probably headed for a high court challenge.

Prime Minister Benjamin Netanyahu supports the legislation and has told his constituents that no government had done more for the settlers. On Monday, the Israeli leader said he had informed the Trump White House that a vote on the legislation was imminent.

Israeli legislators in the opposition condemned the bill as reckless and warned that it would turn the world against Israel while goading prosecutors at the International Criminal Court in The Hague to take action against the Jewish state.

The private Palestinian land would be seized by the government and held until there is a final resolution of the decades-long Israel-Palestinian conflict. Palestinian landowners could apply to the state for annual rents or be given another parcel.

Benny Begin, a member of parliament in Netanyahu’s Likud party and son of former prime minister Menachem Begin, spoke before the vote and labeled the measure “the robbery bill.”

Another Likud party member, former justice minister Dan Meridor, condemned the bill as “evil and dangerous.”

Meridor, a lawyer, warned the Israeli parliament that the West Bank remains under a “belligerent occupation” 50 years after Israel won the territory from Jordan in the 1967 Arab-Israeli war. Palestinians who live in the territory are not Israeli citizens. They don’t vote in Israeli elections. They live under a military authority.

If Israel’s parliament legislates for the Palestinians — rather than controlling them by military rule — then Palestinians would have the right to become citizens and vote in Israel, Meridor argued.

“Don’t cross a line we’ve never crossed before,” Meridor pleaded in a newspaper column. “No government in Israel has applied its sovereignty to the West Bank.”

The Palestinian Authority said the measure was “an illegal land grab.” Former Palestinian peace negotiator Saeb Erekat compared the Israelis to “looters.”

Last week, White House press secretary Sean Spicer said in a statement that new settlement construction in the West Bank “may not be helpful” in achieving a Middle East peace — a mild rebuke compared with those by the Obama administration. President Trump and Netanyahu are scheduled to meet in Washington next week.

The settlement legalization measure was pushed forward by Naftali Bennett, the education minister and leader of the Jewish Home party, who opposes granting the Palestinians a state and instead wants to annex to Israel the 60 percent of the West Bank where the Jewish settlements are located.

Bennett, a religious nationalist, said the bill seeks to “normalize” life for the settlers and allow them to remain in homes that the state has encouraged them to build, while providing roads, water, power and protection by the army.

After the bill passed, Bennett tweeted just one word: “Revolution.”

There are about 400,000 Jews in the West Bank and an additional 200,000 in East Jerusalem living in settlements. Most of the world considers the settlements illegal, but Israel disputes that.

Shuli Moalem-Refaeli, one of the bill’s sponsors, called it “a historic achievement and a strategic event for the settlement movement. It’s another step in normalizing the lives of thousands of citizens. The fate of thousands of homes will no longer be dependent on the whims of left-wing organizations.”

She was referring to the forced eviction of 40 families living in the Amona settlement. Lawyers with the Israeli human rights group Yesh Din successfully argued that the land was owned by Palestinians in the nearby village of Silwad.

The Amona settlers said God had promised the land to the Jews and denied the Arab claims. The Israeli supreme court ordered the settlement demolished. It took 3,000 police officers to clear the isolated hilltop of radical youths, who threw excrement, bleach and rocks at the officers.

The Israeli anti-occupation group, Peace Now, estimated that more than 3,800 homes on 53 illegal outposts could eventually be legalized by the bill, which they claimed “would turn Israeli citizens into thieves.”

A pro-settler advocacy organization, Regavim, said the number of protected homes is half that.

Reporters in parliament said the most recent revised version of the bill would safeguard homes in 16 settlements but that the justice minister could add to this list.

The law will almost certainly be challenged in the courts by pro-Palestinian groups and human rights activists in Israel who say it upends Israel’s own protections of private property.

Before its passage, Israeli Attorney General Avichai Mandelblit said the bill violates international law and that he would not defend it before the state high court.

Israel’s defense minister, Avigdor Lieberman, who is essentially the military governor of the West Bank, said in the days before the vote, “You don’t have to be a genius to understand that when the attorney general is opposed to the bill, this means that he is not willing to defend it in the High Court of Justice and that it is an unconstitutional bill, and its chances of being disqualified are 100 percent.”