WASHINGTON—A narrower U.S. trade deficit in February and stronger-than-expected economic growth in China suggested the global economy’s outlook may be brightening headed into the spring.

The U.S. deficit on trade in goods and services narrowed 3.4% in February from the prior month, thanks in large part to a pickup in exports, the Commerce Department said Wednesday. Analysts said the smaller deficit suggests U.S. economic growth in the first quarter might have been stronger than previously estimated.

Meantime,...