NEW YORK – US stocks closed down on Friday after a volatile session as investors worried at the end of a rough month for the market about weak US growth data and whether instability in Europe could hurt corporate earnings in the United States.

US economic growth slowed sharply in the fourth quarter as weak business spending and a wider trade deficit offset the fastest pace of consumer spending since 2006.

This came after Greece’s finance minister said the government would not cooperate with the European Union and International Monetary Fund mission.

A brief afternoon rally from rising oil prices failed to stick as investors, nervous about US and global economies, fled to bonds from equities and even sold off utilities stocks, the worst performing sector on the day.

“It feels like a flight-to-safety trade on a month-end. People are putting money into assets that have done well this month,” said Peter Coleman, head trader at ConvergEx Group in New York, who said Friday was a good reflection of the month.

The Dow Jones industrial average .DJI fell 251.9 points, or 1.45 per cent, to 17,164.95, the S&P 500 .SPX lost 26.26 points, or 1.3 per cent, to 1,994.99 and the Nasdaq Composite .IXIC dropped 48.17 points, or 1.03 per cent, to 4,635.24.

The S&P energy sector was the only one to finish up on Friday with a 0.74 per cent increase after falling as much as 1.5 per cent earlier in the session. It rebounded when crude futures rose 8 per cent after a survey showed the biggest decline since 1987 in the number of rigs drilling for US oil.

For the week, the Dow and S&P were each down 2.8 per cent, and the Nasdaq fell 2.6 per cent. For January, the Dow was down 3.6 per cent and the Nasdaq was off 2.1 per cent.

The S&P fell 3.1 per cent in January, which was its biggest monthly loss since January 2014 and its first back-to-back monthly decline since April-May 2012.

Consumer spending was a bright spot as data showed US consumer sentiment rose in January to its highest in 11 years on better job and wage prospects.

That confidence appeared to be reflected in some corporate results. Amazon AMZN.O shares jumped 13.7 per cent after earnings beat Wall Street expectations on strong holiday season sales.

“Winners are being rewarded, whereas the market has really no tolerance for anything that comes up short,” said Randy Bateman, chief investment officer of Huntington Asset Management in Columbus, Ohio.

In contrast to the broader market, shares of burger restaurant Shake Shack SHAK.N rose more than 118.6 per cent in their market debut.

About 8.5 billion shares changed hands on US exchanges, well above the almost 7 billion average for the last five sessions, according to BATS Global Markets.