President Obama delivers a toast during a luncheon hosted by United Nations Secretary-General Ban Ki-moon during the 70th annual U.N. General Assembly. Chip Somodevilla AFP/Getty

President Obama rarely takes the opportunity to talk back to the Republican presidential candidates, especially with top White House aides going out of their way to claim he doesn’t watch their debates or heed their attacks.

But on Monday, the president left little doubt that he has been paying attention to what they’ve been saying on foreign policy. And he thinks they are wrong.

The stage for his response was one where domestic political concerns rarely intrude on global crises, geopolitical strategies, and diplomatic touch points. Ever since Harry Truman inaugurated the annual practice, presidents almost always aim high when they address the opening of the United Nations General Assembly, their message directed at the world leaders arrayed in front of them.

This time, this president did have plenty to say to the leaders of Russia, China, Iran, and Cuba. But not before he made clear just how wrongheaded are the Republicans who have been ripping into his foreign policy for months as feckless, weak, perilous, and even traitorous. He has heard the candidates pledge to break trade treaties in this hemisphere, demand protective tariffs, and threaten to use military force against North Korea, China, Russia, Syria, Iran, and Iraq.

With almost seven years as president under his belt, Obama came across as the elder statesmen saddened by the impetuousness of untested candidates. He suggested that with some seasoning, they will learn what he already knows and recognizes: “that diplomacy is hard, that the outcomes are sometimes unsatisfying, that it’s rarely politically popular.”

His larger message to those fighting for his job is not to give up on multilateral institutions and the international order built so arduously under American guidance in the seven decades since the end of World War II. “There are those who argue that the ideals enshrined in the U.N. charter are unachievable or out of date—a legacy of a postwar era not suited to our own,” he said. “Effectively, they argue for a return to the rules that applied for most of human history and that predate this institution: the belief that power is a zero-sum game; that might makes right; that strong states must impose their will on weaker ones; that the rights of individuals don’t matter; and that in a time of rapid change, order must be imposed by force.”

Russian President Vladimir Putin was the ostensible target of that remark. But it also reflected the repeated promises of military force heard in the GOP debates. More directly, Obama lamented what he sees in Western and American politics, complaining that “the increasing skepticism of our international order can also be found in the most advanced democracies.”

He added, “We see greater polarization, more frequent gridlock; movements on the Far Right, and sometimes the Left, that insist on stopping the trade that binds our fates to other nations, calling for the building of walls to keep out immigrants. Most ominously, we see the fears of ordinary people being exploited through appeals to sectarianism, or tribalism, or racism, or anti-Semitism; appeals to a glorious past before the body politic was infected by those who look different, or worship God differently; a politics of us versus them.”

Lest there be any doubt of his target, he declared that the United States “is not immune” from the affliction. “Even as our economy is growing and our troops have largely returned from Iraq and Afghanistan, we see in our debates about America’s role in the world a notion of strength that is defined by opposition to old enemies, perceived adversaries, a rising China, or a resurgent Russia; a revolutionary Iran, or an Islam that is incompatible with peace. We see an argument made that the only strength that matters for the United States is bellicose words and shows of military force; that cooperation and diplomacy will not work.”

While the Republicans repeatedly assert he has let the American military muscle atrophy, he insisted, “I lead the strongest military that the world has ever known, and I will never hesitate to protect my country or our allies, unilaterally and by force where necessary.” He warned against overuse of that military, though.

“No matter how powerful our military, how strong our economy, we understand the United States cannot solve the world’s problems alone,” he said. “In Iraq, the United States learned the hard lesson that even hundreds of thousands of brave, effective troops, trillions of dollars from our Treasury, cannot by itself impose stability on a foreign land. Unless we work with other nations under the mantle of international norms and principles and law that offer legitimacy to our efforts, we will not succeed. And unless we work together to defeat the ideas that drive different communities in a country like Iraq into conflict, any order that our militaries can impose will be temporary.” 

Obama seemed to be looking beyond the Republican candidates with a message for American voters who are voicing support for the GOP pitch. “A politics and solidarity that depend on demonizing others, that draws on religious sectarianism or narrow tribalism or jingoism, may at times look like strength in the moment, but over time its weakness will be exposed,” he warned. “And history tells us that the dark forces unleashed by this type of politics surely makes all of us less secure. Our world has been there before. We gain nothing from going back.”

We want to hear what you think about this article. Submit a letter to the editor or write to letters@theatlantic.com.