On the morning of June 5, 1967, as Arab armies and Israel clashed following weeks of tension, Rabbi Irving “Yitz” Greenberg sat anxious amid his congregants at daily prayers — fearful that the Jewish people would face extinction for the second time in 25 years.

“One of the people said, ‘They’re going to wipe out Israel. What’s going to be?’” recalled Greenberg, then the spiritual leader of a synagogue in the Riverdale section of the Bronx.

“I said, ‘They’re not going to wipe out Israel, and if they do, there’s going to be a sign up: The shul is closed.’ Faith could not go on with an unmitigated catastrophe of that size happening again.”

The fear felt by Greenberg pervaded the air in American Jewish communities that week. Two decades after the world learned the full extent of the Holocaust, Americans looked on from afar as Egypt and Syria threatened the young Jewish state.

But many American Jews, haunted by their failure to act during the Holocaust, didn’t just passively watch events unfold — they decided to mobilize. They raised tens of millions of dollars. They held rallies. They lobbied President Lyndon Johnson.

Within days, however, the fear turned to relief. The relief turned to pride when Israel won the war in six days, tripling its territory and taking control of Judaism’s holiest sites.

The Six-Day War, as it quickly became known, intensified American Jews’ love for Israel and imbued them with a new confidence to advocate for their interests at home and abroad. And the terror that consumed the community in the run-up to the war led to an increased emphasis on Holocaust remembrance.

The shift from terror to power experienced by the Jewish community in June 1967 set up Holocaust memory and support of Israel as the twin poles of American Jewish identity. At the same time, however, it sparked debates on territory, history, identity and occupation — issues that continue to consume American Jews 50 years later.

“There was an emotional trajectory that united Jewish people in a way I don’t think we’ve ever seen since the revelation at Mount Sinai 3,500 years ago,” said Klein Halevi, author of “Like Dreamers,” a chronicle of Israel’s Six-Day War generation. Growing up in Brooklyn, he recalled “moving from existential dread to relief when we realized that Israel had taken the offensive.”

American Jews poured their money into supporting the embattled state — creating a precedent (and expectations) for Jewish philanthropy for decades to come, historians say. In the New York City area alone, the United Jewish Appeal raised more than $20 million during the week of the war, nearly $150 million in today’s dollars.

NEW YORK, UNITED STATES – CIRCA 1967: Demonstration for Israel and against the USSR during the Six Day’s war. New York (USA), 67th rue-Lexington Avenue, june 1967. (Photo by Roger Viollet Collection/Getty Images)

Greenberg recalls a congregant taking out a second mortgage to donate $20,000 to Israel. In the New York suburb of Scarsdale, seven high school students raised $10,000 from their neighborhood on the war’s second day.

“The unbelievable amounts of money that were collected before and during the war, nobody had ever seen anything like it,” said Sarna, a professor of Jewish history at Brandeis University. “American Jews didn’t want people to say we did nothing. There wasn’t much they could do, but they knew they could give of their wealth.”

Jews also took to the streets to support Israel. On June 8, the third day of the war,50,000 Jews rallied outside the White House, already demanding that Israel be allowed to keep its battlefield gains. The day after the war, 20,000 Jews filled Madison Square Garden to cheer the victory.

While Jews had protested en masse before, the war showed Jewish leaders how powerful demonstrations could be, said Jack Wertheimer, a Jewish history professor at the Jewish Theological Seminary. The victory also gave American Jews an increased assertiveness to advocate for their own interests. Israel’s victory energized the movement to free Soviet Jewry, which would go on to organize large rallies in Washington, D.C., and protests at Soviet consulates, missions and cultural events across the country.

“Israel has been very good for American Jewish leaders,” Wertheimer said. “The emergence of Israel as a player on the international stage made it possible for American Jewish organizations to ratchet up their presence.”

ALUF SHARON WITH FIELD COMMANDERS AT THEIR HEADQUARTERS.

American Jews also became far more comfortable displaying their love for Israel, and Americans in general supported Israel in the war. Cold War calculations led the U.S.-Israel alliance to grow stronger, while among Jews, expressions of Israeli culture increased in America. The war led more American synagogues to adopt Israeli pronunciations of Hebrew, Wertheimer said, and to use Israeli melodies for prayers. Klein Halevi remembers his doctor decorating his waiting room with an enormous photo of Israeli Defense Minister Moshe Dayan.

“It really intensified a sense of Israel being central,” Sarna said. “American Jews love moments when their Americanness and their Jewishness reinforce one another. There’s this sense that the Six-Day War is a victory for America and for the Jewish people.”

Jews also began traveling more to Israel, which experienced a period of euphoria following the war. Immigration to the Jewish state rose steadily in the late 1960s and early ’70s, and American Jews would later have a disproportionate presence in the settlement movement. While American Jews make up about 5 percent of Israelis overall, they comprise 15 percent of West Bank settlers, according to Oxford professor Sara Yael Hirschhorn, author of the recent book “City on a Hilltop,” about American Jews in the settlement movement.

“There was just this spontaneous need on the part of Jews and the world to physically connect to Israel because of this feeling that we almost lost Israel,” said Klein Halevi, who has written about channeling his own Jewish fears and pride into the militant Jewish Defense League — a youthful flirtation with extremism he eventually left behind. An Israeli since 1982, he recalled the post-war euphoria spoken about in Israel, where “there was this feeling that Jewish history is over, and we won. Certainly the wars were over. The Arabs would never be foolish enough to attack us again.”

Even amid the celebration, cracks of discord began to appear. Jewish leaders bristled at criticism from liberal Americans who had allied with Jews on domestic policy fights like civil rights. Criticism of Israel’s military gains from some African-American leaders further weakened a once strong black-Jewish alliance that had begun fraying half a year earlier, when the Student Nonviolent Coordinating Committee expelled its white members.

“In the liberal camp, there’s a hostility directed at Israel” following the war, Wertheimer said. “American Jews looked upon these individuals as their allies, as their colleagues in some of the great battles. They could not begin to understand why, when it came to this matter, these allies turned on Israel.”

Half a century after the victory, organized American Jewry wrestles with its legacy. Fundraisers and activists lament that there isn’t the same kind of unifying cause around which Jews can rally. Committed activists are split among a right wing that feels G-d delivered into Jewish hands a land that can never again be divided, and a left wing that sees the war and the decisions made in its aftermath as the start of what has become Israel’s most intractable problem: control of millions of Arabs living on lands seized during the victory.

Five decades later, says Hirschhorn, the joy felt in 1967 has faded for many American Jews born long after the war. They don’t remember the Six-Day War as a massacre averted or a near miraculous victory of David over Goliath. For Jews with memories of 1967, Hirschhorn said, feeling strong was an exhilarating experience. Now American Jews are still grappling with the meaning of Jewish power.

“The pride they felt in that moment has changed for our generation, who look at it in a different way and have seen the outcome of the war,” said Hirschhorn, who was born well after the war. “Now the question of our generation is, how do you manage Jewish power responsibly, whether that’s in the State of Israel or outside of it?”