President Donald Trump’s decision to walk away from the nuclear deal his predecessor negotiated with Iran represents a giant gamble, easily the biggest of his presidency so far.

More precisely, the move represents a series of gambles—bets that Iran’s leaders, its economy and its people, as well as America’s allies and even the leader of North Korea, will react the way the president hopes. Mr. Trump may well win those bets, but the dangers that would accompany a loss are quite high.

The...