U.S. retail sales rose in July -- soothing economic jitters in a wild week on Wall Street. Markets applauded the result, as stocks traded higher Friday.

Retail sales in July posted their biggest gains since March, tempering fears that the world's largest economy might be slipping back into recession. Sales increased 0.5 percent, in line with analyst forecasts after an upwardly revised 0.3 percent gain in June, according to Commerce Department data released Friday.

Since consumer spending accounts for two-thirds of U.S. economic activity, U.S. markets that swung wildly up and down this past week settled on the news. Anything below expectations could have sent markets plummeting downward again.

Excluding autos, sales increased 0.5 percent, well above forecasts for a 0.2 gain. The figures were boosted by a 1.6 percent increase in gasoline station sales, due to a rise in fuel costs. Furniture stores, clothing stores, and non-store retailers including online retailers, also posted gains in July.

Department store sales fell, as price-cutting in the category to drive business in the slow-growth economy among leading chains put a dent in revenue. Still, some department stores are doing well despite slight decreases in same-store sales. Kohl's Corp. reported this week, for instance, that its profits increased 17 percent in the second-quarter despite a 1.9 percent drop in same-store sales.

The markets reacted positively to the July sales data, as the Dow climbed 93.85 points, or 0.84 percent, to 11,237.16 by 10 a.m. ET on Friday. The Nasdaq was up 3.24 points, or 0.13 points, to 2,495.76, and the S&P 500 index was up 10.11 points, or 0.86 percent, to 1,182.75.

"When you look at the overall data that's been coming out, it's really a mixed bag, and this shows that the economy is not falling off its wheels," said Rudy Narvas, senior economist at Societe Generale in New York, in Reuters.

Opening market winners included LinkedIn (NASDAQ: LNKD), up 4.32 percent, and Netflix (NASDAQ: NFLX), up 2.4 percent.