All three major stock indexes eked out gains to close at a record for a second session in a row Wednesday, but trading was subdued as investors searched for catalysts that could breathe new life into the rally.
The S&P 500 SPX, +0.08% added 1.89 points to finish at 2,498.37, which was also its intraday high. Energy and consumer discretionary shares led the gains while real estate and health care were big losers.
The U.S. stock market is exhibiting positive short- and long-term momentum, and breadth has expanded enough to lift the S&P 500 to a new all-time high, said Katie Stockton, chief technical strategist at BTIG Research.
Short-term overbought conditions have returned for the S&P 500, but they tend to be managed well when associated with breakouts, which are abundant, Stockton said.
The Dow Jones Industrial Average DJIA, +0.18% edged up 39.32 points, or 0.2%, to end at 22,158.18 while the Nasdaq Composite Index COMP, +0.09% rose 5.91 points to close at 6,460.19.
Stocks spent most of the session flipping between small gains and losses before extending gains into the closing bell. Analysts continue to warn that stocks are overdue for a pullback.
Markets are fully valued now, so earnings will need to catch up to prices. Until the next earnings season begins, we would not be surprised to see sideways moves or a time correction, said Maris Ogg, president at Tower Bridge Advisors.
We could also see a pullback between now than then if there is a catalyst that would spook investors, Ogg said.
Economic news: The producer-price index rose 0.2% in August, mostly thanks to higher gas prices. Core PPI also rose 0.2%, though the 12-month change remains unchanged at 1.9%. The closely watched inflation report is due on Thursday.
See: MarketWatchs economic calendar
Stock movers: Shares of Apple Inc. AAPL, -0.75% slipped 0.8%. The tech giant on Tuesday revealed its new lineup of gadgets, but the much anticipated new flagship iPhone X wont be delivered until November.
Read: Delayed iPhone X launch pressures Apple stock
Centene Corp. CNC, +8.01% climbed 8% after the health insurer said late Tuesday it has signed an agreement in which Fidelis Care will become Centenes health plan in the state of New York.
SeaDrill Ltd. SDRL, +20.24% surged 20% after the offshore driller said late Tuesday it has filed for bankruptcy protection and agreed to a major restructuring plan with its senior lenders.
Western Digital Corp. WDC, -3.42% dropped 3.4% after losing out on a Toshiba Corp. 6502, -2.42% deal. Toshiba said it had picked a consortium led by Bain Capital, instead of Western Digital, to buy its chip business for more than $18 billion.
Nordstrom Inc. JWN, +5.97% rallied 6% after a report late Tuesday that the retailer is taking steps to go private.
Other markets: Oil prices advanced, with the U.S. crude benchmark CLV7, -0.14% rising more than 2%. The gain came after reports that the Organization of the Petroleum Exporting Countries is considering adding more non-cartel members to its output deal. In addition, the International Energy Agency said there are signs the oil market is tightening.
Gold prices GCZ7, -0.18% fell while the greenback strengthened, with the ICE Dollar Index DXY, +0.05% gaining 0.6%.
Stocks in Asia closed mixed, while European indexes were mostly higher even as U.K. stocks slid.
Sara Sjolin contributed to this article.