The story of the war between Israel and Hamas in Gaza in the summer of 2014 is not a complicated one. In June, Hamas operatives activated long-in-the-works plans to escalate terror operations in the West Bank and military attacks from Gaza. Israel responded by launching Operation Brother’s Keeper and then Operation Protective Edge, which were aimed respectively at eroding Hamas’s terror infrastructure in the West Bank and its military infrastructure in Gaza. By the middle of August, Jerusalem announced that Israeli security forces had secured the strategic goals of both campaigns.

This is what happened. And yet the simplicity of this account bothers a great many people. There remains sustained disagreement on the most basic origins of the violence. There remains substantial debate regarding the course of the war in Gaza. There should be little disagreement: 1) Hamas caused the violence; 2) Israel prevailed in the military conflict. Now, to say this isn’t to say anything definitive. Everything is not going to be just fine in the wake of the summer of 2014. Hamas will still pose a threat; Israel’s policies toward the Palestinians will remain controversial.

But in fact, Israel’s strategic position—with no army in the Middle East capable of launching a full-scale invasion and with a Palestinian leader who at least says out loud that the Jewish state is not going anywhere—has never been stronger. The country emerged from the summer’s violence more secure rather than less secure.

Things could have gone differently, and had it not been for the decision made by various Hamas leaders and operatives to drag Israeli security forces into Palestinian-controlled territories, they probably would have.

We now know that Hamas operatives in the West Bank were preparing to generate a massive wave of violence designed to radicalize the territory politically, make Israeli–Palestinian security cooperation impossible, and deprive the Palestinian Authority—which is controlled by Hamas’s rival,

Fatah—of critical Israeli intelligence and strength of arms. With money from Hamas’s Gaza leadership, and under the auspices of the group’s Turkey-based commander, Saleh al-Arouri, the West Bank plotters had for years been preparing for their coming terror war by building infrastructure and stockpiling weapons. Hamas would use violence and the Palestinian Authority’s isolation, so the plan went, to overthrow its reign in the territories as it had done almost a decade ago in Gaza.

Meanwhile, in Gaza, Hamas leaders had prepared a series of strategic “surprises” (their language) in anticipation of a full-blown military confrontation with the Israel Defense Forces. Various ordnances and tactics had been readied with an eye on executing mass-casualty attacks against Israeli civilians. The Muslim Brotherhood’s year-long regime from 2012 to 2013 in Egypt had allowed Hamas’s smuggling operations into and out of Egyptian territory to flourish, and Hamas was able to import through its tunnels dozens of advanced M-302 rockets powerful enough to reach the outskirts of northern Israel. Terrorists had slipped in and out of Gaza for hang-glider training and were preparing to replicate tactics that had facilitated some of the Palestinians’ most devastating terror attacks. Drones had been acquired; Hamas leaders boasted that some were packed with explosives for suicide missions. Meanwhile, Hamas had diverted hundreds of thousands of tons of cement (given as humanitarian aid) into the construction of 32 attack tunnels that ran under the Israel-Gaza border. Teams of commandos were readying to infiltrate Israel through those passages, which would empty them out a few minutes away from sparsely populated and lightly defended Israeli communities.

All of it was gone by mid-August. In the West Bank the coup plotters had been rounded up, their weapons had been seized, and Hamas’s leaders had been captured. In Gaza, the long-range rockets had been blown up or wasted, the hang-glider plot had been disrupted, the drones had proven useless, and the tunnels had been destroyed.

The unanswered question, then and now, is this: Why did the terror group decide to provoke the Israelis into war before its operatives could carry out their spectacular mass-casualty plot? The conventional wisdom, which has much to recommend it, is that a year of pressure brought to bear on Hamas by Egypt’s post-Brotherhood government combined with Israel’s steadfastness had brought the terror group to the brink of collapse. The Egyptian army destroyed the smuggling tunnels that had been the primary conveyors of goods and a huge source of revenue for Hamas. Hamas had no funds to pay its more than 40,000 employees. Its control of Gaza was slipping.

Authoritarian governments are almost always weaker than they look from the outside but stronger than their paranoid leaders perceive them to be from the inside. Hamas’s top figures may have calculated that they were in a use-’em-or-lose-’em situation and lashed out (so the theory goes) in hopes of arriving at a better position on the other side. Another theory holds that Hamas’s leaders feared that the information Israel gleaned in the course of Operation Brother’s Keeper—launched against Hamas assets in the West Bank following the kidnapping of three Israeli teenagers—had blown the secret of their planned attacks from Gaza, and, with nothing left in their quiver, Hamas chose to strike in desperation.

Then again, the explanation could be much simpler: Terrorists are often not very bright, fanatics as a rule lack prudence, and one way of viewing history is as a series of consequential blunders.

Maybe Hamas just screwed up.

Whatever the reason, escalate Hamas did. In Gaza, Hamas radically escalated what had been, since the beginning of the year, a steadily increasing stream of rocket fire. Israeli Defense Minister Moshe Yaalon had declared in January that Jerusalem would “not tolerate rocket fire” and that the “IDF and other security forces will continue to chase after those who shoot at Israel.” February saw more rockets and a large bomb planted on the border. In March, Hamas fired its heaviest rocket barrage since the conclusion of Israel’s 2012 incursion into Gaza—but then the fire steadily decreased throughout April and May.

It spiked again on the first day of June, when a rocket slammed into Israel’s Eshkol region. On June 11, another rocket was launched, this time barely missing one of Israel’s main transportation routes. That night the Israeli Air Force, aided by the country’s security agency, the Shin Bet, targeted a former Hamas police officer responsible for rocket attacks. By the end of the month, at least 65 rockets and mortars would be fired at Israel.

Meanwhile in the West Bank, amid the escalation that had already begun along Israel’s southern border, Hamas terrorists kidnapped and murdered three Israeli teenagers: Naftali Fraenkel, Gilad Shaar, and Eyal Yifrach. Citing intelligence that had been convincing enough to generate immediate and definitive condemnations from Washington and Ramallah—information that later turned out to involve details of the coup plot aimed at PA President Mahmoud Abbas—the Israelis quickly blamed Hamas. They would later identify Marwan Kawasmeh and Amar Abu-Isa as suspects.

With the help of outraged PA officials—who had inked a unity deal with their Palestinian rivals only days before the kidnapping and now realized that they had been manipulated—the Israelis immediately launched Operation Brother’s Keeper to find the perpetrators and in the process uproot Hamas from the West Bank. The teens, whom Israeli officials strongly suspected had been killed early in the course of the abduction, were found dead on June 30.

Even after this discovery, Israel hoped to avoid an escalation in the south. On July 3, Prime Minister Benjamin Netanyahu announced that Hamas still had the option of halting its attacks and reverting to the “quiet for quiet” arrangement that had characterized the border for almost two years. Israel made it clear, through public and private channels, that the Palestinian group had no more than the weekend to decide.

Hamas’s foreign-relations chief, Osama Hamdan, said the next day that rocket and missile fire would continue until Israel lifted its import restrictions on Gaza and the PA transferred salary money to Hamas. The precision of these conditions would later provide fodder for those who argued that Hamas leaders had been driven by a try-or-die mentality.

An Egyptian effort to end the war before it began never got very far. On July 7, dozens of barrages were launched at Israeli population centers. The tempo of the attacks reached as high as 30 rockets in 10 minutes. Israel commenced Operation Protective Edge that night. Hamas ended up breaking cease-fires and renewing the fight no fewer than 11 times over the 50-day course of the operation. It pressed the fighting even as the war objectively went from bad, to worse, to disastrous.

A full tally of the destruction that Hamas brought to itself and to Gaza will not be possible to know for months. Preliminary reports suggest near-total devastation of Hamas’s infrastructure. Eighty percent of the group’s projectile arsenal was depleted. Many of the rockets were destroyed by Israeli airstrikes, and almost all the rest either landed in empty fields, were swatted down by the anti-projectile system Iron Dome, or fell short and landed in Gaza. Hamas’s 32 attack tunnels were destroyed after Israel launched the operation’s ground phase on July 17. Only two days earlier, the group’s leaders had rejected a cease-fire that would have preserved that infrastructure; they instead deployed a group of commandos through a tunnel with the intention of raiding a small kibbutz.

At least three of Hamas’s very top military leaders were killed in the closing days of the war. They had made a frankly inexplicable decision to leave their underground bunkers after breaking yet another ceasefire. By the time Israel was through, roughly 1,000 Hamas fighters had been killed. Fully zero percent of Hamas’s spectacular attacks on civilians—to be conducted via long-range rockets, drones, hang gliders, and tunnels—succeeded.

And Israel? A total of 72 Israelis—66 soldiers and 6 civilians—died. Israel’s international airport was shut down for just over a day, which was Hamas’s strategic high-water mark.

Even this grim accounting fails to convey the scope of Hamas’s military debacle. The nature of the fight—the how’s and where’s—was entirely controlled by Israel. Hamas was capable of forcing the Israelis to fight, but there their control ended. The IDF’s July 17 ground invasion lasted precisely as long as Israeli leaders wanted to stay in the territory. After Hamas scuttled an 11th attempted cease-fire, the Israelis began on August 19 what they described as an “extraordinary escalation,” targeting top military leaders and leveling at least three multistory command-and-control centers.

Hamas capitulated within a week, accepting the very same terms that had been on the table for more than a month and that had been widely considered to be favorable to Israel and humiliating to the Palestinian faction. Victory parades were held in Gaza that fooled only the willingly fooled. Abbas called on Hamas to admit that it had been soundly beaten and adjust accordingly. Hamas Prime Minister Ismail Haniyeh crawled out of his bunker and returned to his home, which had been destroyed during the war.

In what must be counted as the perfect distillation of Operation Protective Edge, Haniyeh posed utterly alone with a slack-jawed grin, surrounded on all sides by rubble and only rubble, and flashed a victory sign.

Even so—and perhaps predictably—an idea has developed that Israel somehow lost the war, or at the least failed to meet its own expectations. These notions are simply wrong. Israeli leaders had declared as far back as June that they were uninterested in overthrowing Hamas. Any such task, they explained, would require an invasion of the Gaza Strip that would take many months, followed by a reoccupation of the territory that would last for years. Instead of spending the next half-decade focused on the south, Israeli leaders sought to reestablish “quiet for quiet” and then to get to work on the remainder of Hamas’s arsenal via diplomatic channels. Even though the latter option had only a marginal chance of success, it was still considered preferable to the 100 percent certainty of a protracted and distracting conflict.

As proof that the Netanyahu government had not in any way welcomed the opportunity for making war on Hamas, Jerusalem chose to accept an Egyptian cease-fire. Hamas rejected it because it met none of the group’s terms and then launched a quickly thwarted tunnel attack. Israel then responded by explicitly declaring that the goal of the campaign remained the reestablishment of “quiet for quiet,” not the destruction of Hamas—but that in the meantime the IDF would be launching a ground invasion and destroying Hamas’s offensive tunnel network.

On July 22, Israeli Justice Minister Tzipi Livni explained that a cease-fire “won’t happen before we really finish the tunnels project…[and] won’t happen in a way in which Hamas’s completely unacceptable conditions are met.” Israel completed the tunnel work and withdrew, Hamas broke several subsequent cease-fires, Israel launched its “extraordinary escalation,” and then the war was over.

Netanyahu took criticism from both sides throughout the conflict. The left blasted him for expanding the campaign beyond stopping the rocket fire—to destroying the tunnels, waging a ground war, and so on—while the right attacked him for refusing to expand the campaign beyond stopping the rocket fire. For example: On August 20, Foreign Minister Avigdor Lieberman (on Netanyahu’s right) took to Facebook to declare that “quiet met with quiet” would never work, and that Israel must go further. On August 22, Yossi Sarid, who for many years led Israel’s left-wing Meretz Party, called on Israel’s southern residents “to explain to the politicians and the generals that another Pillar of Defense and another Cast Lead and another Protective Edge will not scatter the black cloud of enmity” with the Palestinians.

The frustration felt by many Israelis over the conclusion of the conflict is understandable. Hamas’s eventual capitulation left many of the group’s leaders, and even more of its fighters, alive to fight another day. Israeli civilians still have genocidal Hamas fanatics living next door to them. Still, a couple of inconvenient facts are worth noting. They point to Israel’s substantive victory and seem misunderstood by many Western pundits. The confusion sometimes seems to proceed in ways suspiciously supportive of a hostile posture toward Israel itself, or toward Benjamin Netanyahu’s leadership more specifically.

Much has been made, for instance, of a precipitous drop in Netanyahu’s approval rating following the war’s conclusion; it has fallen from wartime highs in the 80s to the mid-to-low 30s. The decline has been greeted by his overseas critics with smug satisfaction and as a confirmation of their own belief in his and Israel’s wartime failure. But lost in the noise is any perspective on Israeli polling and public sentiment itself. Netanyahu now stands a bit higher than his natural median. Polls that have asked about his electability find that he still beats any challenger by a margin of 2-to-1.

It is conceivable that Israel and Netanyahu will yet emerge as long-term losers. Perhaps fighting will resume and Israel will take substantial losses in the time it takes to craft the next cease-fire. Perhaps negotiations now or later will allow Hamas to secure the core demands it long insisted were prerequisites for a truce, but turned out not to be: cash for its workers, relief from Israeli import restrictions, the opening of Gaza’s border with Egypt. (Since the war ended, Jerusalem has agreed to expand Gaza’s fishing zone from three miles to six miles, a gesture that was already being considered but that still technically counts as something Hamas had asked for.) It would not be the first time that the Israelis had allowed the fruits of military victory to slip through their fingers.

None of this changes the key fact: Hamas is isolated and broken. Militarily, it could not have continued to fight beyond a couple more weeks. Diplomatically, battlefield losses tend to position the losers poorly in subsequent talks. It is more likely that the full scope of Israel’s victory will begin to sink in.

Israel used the war to forge new relationships with its neighbors. The bloc of so-called Arab pragmatists traditionally allied with the United States—Saudi Arabia, Jordan, the Egyptian army, elements of the Palestinian Authority—sees Israel standing in opposition to Shiite Iran on one side and an axis of extremist Turkish/Qatari/Muslim Brotherhood types on the other. These are the enemies of the pragmatists. It’s no wonder, therefore, that Israel and the new Egyptian government worked together so closely to isolate Hamas. And it would be no surprise if they continued to find common ground.

Egypt will continue to limit materials to Hamas. So if there is a rebuilding process, the Palestinian Authority will be brought in to manage it. That’s a gambit that’s not without risk. Managed badly, the rebuilding process could end up with the PA having nominal control of civil institutions, Hamas having de facto control through strength of arms, and Israel being under nearly impossible pressure to spare damage to “PA” infrastructure in any future conflagration. This would lock in a kind of “Hezbollah model” for the Palestinians. But there is no love lost between Fatah and Hamas, and the latter will be humiliated by having to allow the former back into Gaza.

More important, Israel’s attention has been turned to the military threat posed by attack tunnels, and this focus may avert a catastrophe in another war. Israel has a remarkable record of developing amazing technological solutions to asymmetric threats, but only after it has been forced to pay attention. Israeli intelligence knew for the better part of a decade that Yasir Arafat was preparing for a war that would be waged by terrorists infiltrating from the West Bank. But only after waves of suicide bombers had attacked family pizzerias and Passover banquet halls did the Israelis innovate and build their high-tech security fence. Similarly, Israel knew that Hezbollah was importing tens of thousands of rockets and missiles during the early 2000s. Only after northern Israel was saturated by Hezbollah rockets and missiles did Jerusalem begin seriously pursuing missile-defense technology. Hezbollah has undoubtedly dug its own network underneath Israel’s northern border in anticipation of war. Israel has now set to work and is focused on protecting itself from below as well as above. Hezbollah and its Iranian sponsors will not thank Hamas for having awakened the Jewish state.

This is what victory looks like. It is not total victory, but total victory was never sought. In the summer of 2014, Israel was forced to defend itself—and it did so, brilliantly.