NEW YORK (Reuters) - U.S. stocks closed higher on Tuesday after an announced delay of planned tariffs on some Chinese imports brought buyers back to the equities market in a broad-based rally.

Tech stocks, headed up by Apple Inc AAPL.O, led all three major U.S. indexes into the black following the announcement, which calmed fears over the U.S.-China trade war and growing signs of imminent recession.

U.S. Trade Representative Robert Lighthizer said the United States would hold off on imposing additional 10% tariffs on key Chinese goods, including laptops and cellphones, tariffs that were originally set to go into effect next month.

“It’s a stemming of the downward momentum because it does give some trade optimism,” said Joseph Sroka, chief investment officer at NovaPoint in Atlanta. “We’re getting into the tail end of earnings season, so geopolitical and macroeconomic news will dominate the markets direction for the next few weeks.”

Apple, a likely beneficiary of the tariff delay, rose 4.2% on Nasdaq, while the Philadelphia SE Semiconductor Index .SOX gained 3.0%.

In economic news, U.S. consumer prices USCPFY=ECI accelerated in July, with core CPI, which strips out volatile food and energy prices, growing at 2.2% year-on-year, its largest gain in six months and well above the U.S. Federal Reserve's 2% target.

The healthy inflation reading is unlikely to change market expectations for another interest rate cut from the Fed next month as it grapples with the U.S.-China trade war and its economic fallout.

Slideshow ( 7 images )

“Trade issues could really disrupt economic growth,” Sroka added. “And if the Fed cuts (interest) rates in September, it could be considered a safety net, to be proactive rather than waiting until it’s too late.”

The spread between 2-year and 10-year U.S. Treasuries hit its flattest level in 12 years, reflecting anxieties over trade and geopolitical turmoil. But yields rose across the board on news of the tariff delay.

The Dow Jones Industrial Average .DJI rose 372.54 points, or 1.44%, to 26,279.91, the S&P 500 .SPX gained 42.48 points, or 1.47%, to 2,926.23 and the Nasdaq Composite .IXIC added 152.95 points, or 1.95%, to 8,016.36.

All of the 11 major sectors in the S&P 500 closed in the black, with technology .SPLRCT and consumer discretionary .SPLRCD seeing the biggest percentage gains.

Toys and footwear were among the Chinese goods temporarily spared from additional tariffs.

Nike Inc NKE.N rose 2.0%, while toymakers Hasbro Inc HAS.O and Mattel Inc MAT.O advanced 2.7% and 4.6%, respectively.

Slideshow ( 7 images )

Facebook Inc FB.O pared gains following a Bloomberg report that the social media company had hired outside contractors to transcribe user audio clips, ending up 1.7%.

Shares of CBS Corp CBS.N and Viacom Inc VIAB.O gained 1.4% and 2.4%, respectively, after sources told Reuters the companies had reached an agreement in principle regarding their impending merger.

The second-quarter earnings season has reached the final stretch, with 453 of the companies in the S&P 500 having posted results. Of those, 73.3% beat consensus estimates, according to Refinitiv data.

Analysts see S&P 500 second-quarter earnings growth of 2.9% year-on-year, a significant improvement over the paltry 0.3% growth expected on July 1, per Refinitiv.

Advancing issues outnumbered declining ones on the NYSE by a 2.46-to-1 ratio; on Nasdaq, a 2.30-to-1 ratio favored advancers.

The S&P 500 posted 31 new 52-week highs and 18 new lows; the Nasdaq Composite recorded 60 new highs and 128 new lows.

Volume on U.S. exchanges was 7.95 billion shares, compared with the 7.34 billion-share average over the last 20 trading days.