Hong Kong (CNN Business) China's huge export industry has suffered its worst month in three years, hurt by the trade war with the United States and a slowing global economy.

Chinese exports plunged 21% in February from a year earlier, according to Chinese government data released Friday. It was the weakest monthly performance since February 2016 and far worse than economists had predicted.

The tariffs imposed last year by the US government on about $250 billion of Chinese products are taking a toll. The value of goods shipped to the United States fell much more sharply than for other major markets, according to the data.

"US tariffs have become a more meaningful drag on exports," Julian Evans-Pritchard, a China economist at research firm Capital Economics, said in a note to clients.

But the trade war, which China and the United States are trying to resolve through negotiations, is only part of the problem. The slump in Chinese exports provides "further evidence that global demand is cooling," according to Evans-Pritchard.

Read More