(AP) -- Stocks on Wall Street closed with modest gains Wednesday, driving the S&P 500 and Nasdaq to all-time highs for the second day in a row.
Financial and energy companies led the way higher among stocks in the S&P 500. The benchmark index rose 0.2%, marking its fifth straight gain. A rise in bond yields, which allows lenders to charge higher interest rates on loans, helped push bank stocks higher. Health care and technology companies were among the laggards.
The market's latest gains came as earnings season continues to wind down and investors wait to hear from the Federal Reserve the next couple of days, when central bank officials hold their annual symposium. Wall Street is keen to gain new insight on the Fed's view of the economy and what action, if any, it is considering taking to tackle rising inflation.
"Earnings are rising, inflation is moderate and interest rates are low, and that typically presents a favorable backdrop," said Terry Sandven, chief equity strategist at U.S. Bank Wealth Management.
The S&P 500 added 9.96 points to 4,496.19. The index is on pace for a 1.2% weekly gain after closing out last week with its first weekly loss in three weeks.
The Dow Jones Industrial Average rose 39.24 points, or 0.1%, to 35,405.50. The Nasdaq gained 22.06 points, or 0.2%, to 15,041.86. The major indexes bounced back from modest declines in the early going.
Small company stocks continued to do better than the broader market. The Russell 2000 index picked up 8.36 points, or 0.4%, to 2,239.27.
Bond yields moved broadly higher. The yield on the 10-year Treasury note rose to 1.35% from 1.28% the day before.
Trading has been mostly quiet this week ahead of the Federal Reserve's annual convention in Jackson Hole, Wyoming, which begins Thursday.
Investors are betting that Fed officials will remain in "wait and see" mode regarding inflation, since most policymakers believe any inflation earlier this year would be temporary and the rise in COVID-19 cases has made some economists worried. Meanwhile there are other Fed officials that say the U.S. central bank needs to start winding down bond purchases to combat inflation.
Fed Chair Jerome Powell is scheduled to speak at the convention on Friday. While the event is a logical opportunity for Powell to reveal new monetary policy, it doesn't mean it's likely to happen, analysts say.
Economic reports have been disappointing recently, and uncertainty about the highly contagious coronavirus delta variant and how it may affect the economy this fall could give Powell pause, said Willie Delwiche, investment strategist at All Star Charts.
"I don't know that he wants to get ahead of that," Delwiche said. "He might take a wait-and-see approach in terms of introducing the next phase of what the Fed is going to do."
Sandven doesn't expect any big news to come out of the gathering of Fed officials.
"We may get some indication out of Jackson Hole as to when the Fed may like to change its course, but I think it's fairly well telegraphed and our belief is that we're not likely to get anything substantial," he said. "And if we do, that's probably going to be a little bit of a disruptor to the broad market."
The KBW Bank Index, which tracks the 24 largest banks in the country, rose 1.8% as financial stocks rallied Wednesday. JPMorgan rose 2.1%.
Industrial stocks and a variety of retailers, homebuilders and other companies that rely on consumer spending also helped lift the market. Deere & Co. rose 2.3%, D.R. Horton added 1.3%, Domino's Pizza gained 2.1% and Caesar's Entertainment picked up 4.1%.
Health care stocks were the biggest decliner in the S&P 500. Pfizer was among the biggest drags on the sector, shedding 1.8%.
Dick's Sporting Goods jumped 13.3% after reporting a surge in quarterly sales and a special dividend.