US President Barack Obama delivered his eighth and final speech to the UN General Assembly on Tuesday, combining appeals for greater international cooperation with denunciations of religious extremism, a self-congratulatory review of his own foreign and domestic policies, and thinly veiled criticism of Republican presidential hopeful Donald Trump.

The address, coming just four months before his term of office ends, was delayed by his late arrival at the heavily guarded UN headquarters in Manhattan. It touched on everything from nuclear disarmament to right-wing populism, income inequality and climate change. Despite the headlines, he asserted, the human condition is improving. “A quarter century after the end of the Cold War, the world is by many measures less violent and more prosperous than ever before, and yet our societies are filled with uncertainty, and unease, and strife,” he said. “This is the paradox that defines our world today.”

Scientific and medical advances, technology, accountable government and free global markets, he continued, had led to reductions in extreme poverty, longer lifespans and greater opportunity than at any other time in history. But at the same time, he acknowledged, these advances “fueled religious fundamentalism; the politics of ethnicity, or tribe, or sect; aggressive nationalism; a crude populism -- sometimes from the far left, but more often from the far right.”

“The answer cannot be a simple rejection of global integration. Instead, we must work together to make sure the benefits of such integration are broadly shared, and that the disruptions -- economic, political, and cultural -- that are caused by integration are squarely addressed.” In a clear dig at Donald Trump and his campaign promise to build a wall along the US-Mexico border, Obama noted that, “today, a nation ringed by walls would only imprison itself.”

Rich versus poor

Reducing income inequality within and among nations was a major theme of the speech – and an unusual one from the head of state of one of the world’s wealthiest and most unequal countries. Mr. Obama deplored the decline of trade unionism in industrialized countries, and criticized the use of tax havens by corporations and rich individuals to hide an estimated $8 trillion in wealth from the tax collector. “A world in which one percent of humanity controls as much wealth as the other 99 percent will never be stable,” he told the assembled heads of state, creating a “pervasive sense of injustice” that undermines public confidence in the existing order.

He encouraged his listeners to adopt economic and social policies similar to his own – policies that he claimed had ended the economic collapse that began in 2008 and created some 15 million jobs since 2009. Globally, he said, his government had worked with other countries to close tax shelters, combat corruption and “curb the 'excesses of capitalism'" – a phrase that might have been borrowed from the socialist Senator Bernie Sanders, who ran a strong but unsuccessful campaign for the Democratic presidential nomination earlier this year. Globally, Mr. Obama noted, supporting weak states and investing in their economies would prevent conflict for a fraction of the cost of the decade-long US occupation of Iraq. “It’s not just the right thing to do, he noted. “It’s the smart thing to do.”

Obama called for concerted international action on climate change, but without making new commitments. He returned instead to the theme of open versus closed societies, arguing that there was a “growing contest” between authoritarianism and liberal democracy around the world. Post-colonial countries with inherited ethnic and cultural divisions, he said, had particular difficulty building democratic societies and were attracted to what he called the “strongman, to-down model” of government. He insisted, however, that democracy was the “better path” to prosperity and development, and listed a number of policies his government had adopted to promote democracy around the world. Conspicuously absent from that list was US support for the coup that ousted the democratically elected government of Honduras in 2009, the overthrow of the elected Ukrainian government in 2014 and close economic and military ties to autocratic regimes in Uganda, Ethiopia, and Saudi Arabia.

He condemned what he termed “any forms of fundamentalism, or racism, or a belief in ethnic superiority” and called for a concerted effort to confront religious, racial and social intolerance: “I do not believe progress is possible if our desire to preserve our identities gives way to an impulse to dehumanize or dominate another group. If our religion leads us to persecute those of another faith, if we jail or beat people who are gay, if our traditions lead us to prevent girls from going to school, if we discriminate on the basis of race or tribe or ethnicity.”

He defended US and NATO military operations in Iraq and Syria aimed at terrorist groups but acknowledged that external powers could not force peace on divided societies for very long, Obama told the international community the US supported a diplomatic solution to the war in Syria, although US warplanes bombed Syrian government forces fighting Islamic State militants only days earlier. In another sign that Mr. Obama’s rhetoric sometimes sat uncomfortably with his actual policies, he called for Palestinians to recognize Israel and reject “incitement” days after agreeing to provide $38 billion in military aid to the Jewish state over the next decade. Nor was the arms deal – the largest such agreement in US history, conditioned on an Israeli commitment to withdraw from the Occupied Territories and respect Palestinian human and political rights.

America: “a force for good”

Africa warranted only two brief mentions in Obama’s nearly hour-long speech, a perhaps surprising omission by the first US president of African descent speaking at his last UN appearance. He concluded his remarks by returning to a favorite topic of US presidents – American exceptionalism. Unlike other superpowers, Obama asserted, the United States abided by international law and worked for the common good, not just national interests. “We have strived, sometimes at great sacrifice, to align better our actions with our ideals,” he asserted. “And as a consequence, I believe we have been a force for good.” It is not difficult to find many flaws in that argument, say historians and researchers, who point to the long history of unilateral US military action covert destabilization in Latin America, Asia and Africa. But it is a popular talking point back home, where many Americans are wary of the United Nations, and among whom interest in foreign affairs and US foreign policy tends to be low.

Mr. Obama concluded his remarks with a call for greater global action to address the refugee crisis and for countries to make good their pledges of more aid made at the UN summit on refugees and migrants held in New York on 19 September. He acknowledged that, in the US and Europe, immigration has become a contentious political issue, but “we have to follow through, even when the politics are hard.” Mr. Obama should know. Although the United States accepts far fewer refugees than other industrialized countries, a recent poll showed 75 percent of his fellow citizens opposed his plans for a small increase in that number.

US President Barack Obama addressing the General Assembly