By Matt Jarzemsky 

U.S. stocks traded mostly higher Friday, with the Dow industrials on pace to cap their biggest monthly gain since February.

The Dow Jones Industrial Average swung between slim gains and losses during the quiet session before the Labor Day holiday weekend, dropping 12 points, or 0.1%, to 17067 in midafternoon trading. Still, the blue-chip benchmark was up 3.2% on the month and headed for its fourth-straight weekly gain.

The S&P 500 added three points, or 0.1%, to 2000. The Nasdaq Composite Index rose 14 points, or 0.3%, to 4572.

Stocks have benefited from better-than-expected corporate earnings, improvement in much of the U.S. economy, and investors' distaste for low-return prospects in such other assets as bonds. That positive backdrop has helped stocks to grind higher on a slow week ahead of Monday's holiday in the U.S., when the stock market will be closed.

When it comes to corporate earnings and the economy, "growth looks relatively modest but, no matter how you look at the equity market, it really doesn't look overvalued," said Margie Patel, who oversees $1.4 billion in stocks and bonds as a senior portfolio manager at Wells Capital Management.

"You could make a case that over the next 12 months, equity returns will be more modest than over the last 12 months," she added. But Ms. Patel said she expects interest rates to remain low, particularly because of the lack of inflation in the U.S. economy, adding, "I think equity returns will surpass those in almost all areas of the fixed-income market."

Traders said the level of activity was low Friday, in line with the market's recent summer lull. So far this week, an average 4.38 billion shares have changed hands daily, 30% below the year-to-date average, according to FactSet.

Shares of particularly risky sectors outperformed. The Russell 2000 index of small companies' shares was up 0.5%. The Nasdaq Biotechnology Index added 0.6%.

Bonds also moved toward closing out a big monthly rally, fueled by optimism central banks will maintain an accommodative stance toward markets. The 10-year U.S. Treasury note was little changed in thin trade Friday, yielding 2.34%. But so far this month, the note's yield--which moves inversely to its price--is on pace for its biggest slide since January.

On the economic front Friday, household spending fell 0.1% in July, the Commerce Department reported, bucking economists' median forecast for a 0.1% increase. Personal income rose a less-than-expected 0.2%.

Russian President Vladimir Putin on Friday used harsh language against Ukraine and its allies over the failure of peace talks. Ukraine has accused Russia of sending troops to fight alongside rebels in eastern Ukraine.

European stocks rose Friday, with the Stoxx Europe 600 adding 0.3%, reversing earlier gains. The euro zone's annual rate of inflation fell to 0.3% in August from 0.4% in July. That is a far cry from the European Central Bank's medium-term target of inflation just under 2%. The continued decline in inflation has added to expectations that the ECB will be forced to take more aggressive action to boost the region's economic recovery.

In corporate news, Avago Technologies rallied 7.2% and hit a record high after the chip company reported better-than-expected quarterly results.

In commodity markets, crude-oil futures rose 1.4% to $95.85 a barrel. Gold futures fell 0.2% to $1,287.90 an ounce.

Write to Matt Jarzemsky at matthew.jarzemsky@wsj.com