Nir Barkat, the mayor of Jerusalem, should hang his head in shame.

Caving in to pressure from the city’s ultra-Orthodox and national religious camp, he announced he would not attend today’s gay pride parade.

“It is their right to march,” he said of the people to plan to participate in the annual event. “The city of Jerusalem, myself and the police will do everything possible to allow them to enjoy that right. But they must know that it offends others.”

It’s a truism that the LGBT community, in Israel and elsewhere in the world, is reviled in some quarters. But that doesn’t mean that elected officials should give in to intolerance and boycott gay parades.

It’s the wrong reaction. It sends a reactionary message. It encourages haters.

I strongly suspect that Barkat was motivated by crass political considerations. Religious Jews form part of his base, and obviously he has no wish to anger and alienate them. But Barkat should not pander to their narrow and unjust demands. He should be everyone’s mayor. He should be sensitive to the needs and wishes of each and every resident of Jerusalem, regardless of sexual orientation.

Israel prides itself on being an open and inclusive society. Israel also goes out of its way to differentiate itself from the mass of Arab countries that disgracefully persecute gays and lesbians on a systematic basis.

But when the mayor of Israel’s capital city capitulates to pressure, or maybe even threats, he is doing himself, Jerusalem and Israel a great disservice. Let Barkat be guided by the mayor of Tel Aviv, Ron Huldai, who shows respect for gay and lesbian fellow citizens.

We know there are crazies in Jerusalem who will stop at nothing to disrupt the parade. Last year, Yishai Schlissel, a dyed-in-the-wool fanatic, went on a murderous rampage as the parade unfolded. As he lashed out at spectators in a protest against gay rights, he killed a bystander, Shira Banki, a 16-year-old girl, in a brutal knife attack.

If only out of respect to Banki and the five bystanders who were injured by that lunatic, Barkat should make an appearance at the parade.

Israel is a rainbow nation, a Tower of Babel that values diversity, but Barkat’s capitulation to intolerance is a disturbing sign that Israel is heading in the wrong direction. He should avoid pandering to elements in the population who would, if they could, turn back the clock and stigmatize those who do not conform to their values.

Israel must rise above their provincialism and be a modern and tolerant state for all its citizens, including those who belong to or identify with the LGBT community.