LONDON — Only a few months ago, the global economy appeared to be humming, with all major nations growing in unison. Now, the world’s fortunes are imperiled by an unfolding trade war.

As the Trump administration imposes tariffs on allies and rivals alike, provoking broad retaliation, global commerce is suffering disruption, flashing signs of strains that could hamper economic growth. The latest escalation came on Friday, when President Trump announced fresh tariffs on $50 billion in Chinese goods, prompting swift retribution from Beijing.

As the conflict broadens, shipments are slowing at ports and airfreight terminals around the world. Prices for crucial raw materials are rising. At factories from Germany to Mexico, orders are being cut and investments delayed. American farmers are losing sales as trading partners hit back with duties of their own.

Workers in a Canadian steel mill scrambled to recall rail cars headed to the United States border after Mr. Trump this month slapped tariffs on imported metals. A Seattle customer soon canceled an order.