LONDON — Well before a deadly virus began spreading across multiple borders, a world defined by deepening interconnection appeared to be reassessing the merits of globalization.

The United States, led by the unabashed nationalist Donald J. Trump, was ordering multinational companies to abandon China and make their goods in American factories. Britain was forsaking the European Union, almost certainly reviving customs checks on both sides of the English Channel, while threatening to disrupt a vital trading relationship.

A surge of refugees fleeing some of the most dangerous places on earth — Syria, Afghanistan, Central America — had produced a backlash against immigration in many developed countries. In Europe, it elevated the stature of extreme right-wing parties that were winning votes with promises to slam the gates shut. President Trump was pursuing the construction of a wall running along the border with Mexico, while seeking to bar Muslims from entering the country.

The coronavirus that has seeped out of China, insinuating itself into at least 81 countries while killing more than 3,200 people, has effectively accelerated and intensified the pushback to global connection.