NEW YORK (Reuters) - Wall Street’s major indexes inched higher on Tuesday, extending their record-setting rally, as strong housing and manufacturing data bolstered investors’ confidence in the U.S. economy.

The benchmark S&P 500 .SPX hit a record high for a fourth straight session, building on its 27% gain this year, which has been driven by progress toward a U.S.-China trade agreement, a dovish Federal Reserve and upbeat economic indicators.

U.S. housing starts increased more than expected in November, and building permits rose that month to the highest level since May 2007. Data from the Federal Reserve also showed manufacturing output picked up more than expected in November, as the end of a strike at General Motors Co GM.N boosted automobile production.

“Most of the data is showing that the global economy is stabilizing and the U.S. economy is on a solid footing,” said Keith Lerner, chief market strategist at Truist/SunTrust Advisory Services in Atlanta. “The market has been repricing the odds of a recession risk lower.”

The Dow Jones Industrial Average .DJI rose 31.27 points, or 0.11%, to 28,267.16, the S&P 500 .SPX gained 1.07 points, or 0.03%, to 3,192.52 and the Nasdaq Composite .IXIC added 9.13 points, or 0.1%, to 8,823.36.

The S&P 500 financial index .SPSY, which tends to be economically sensitive, rose 0.5% to a record high on the upbeat data. Among the S&P 500's major sectors, financials added the most gains to the benchmark index.

Shares of Home Depot Inc HD.N rose 1.0% on the housing data and were among the biggest boosts to the Dow. Shares of rival Lowe's Cos Inc LOW.N dipped 0.6%, however, after having risen earlier in the session.

Netflix Inc NFLX.O shares rose 3.7%, among the biggest percentage gains on the S&P 500, after the streaming service provider said late Monday that its overseas growth, particularly its Asia-Pacific business, was accelerating.

Apple Inc AAPL.O shares touched a record high and ended with marginal gains, up 0.2%.

After the bell, FedEx Corp FDX.N shares fell about 6% after the package-delivery company reported quarterly results.

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

The S&P 500 posted 47 new 52-week highs and no new lows; the Nasdaq Composite recorded 173 new highs and 54 new lows.

Volume on U.S. exchanges was 7.28 billion shares, compared to the 6.89 billion average for the full session over the last 20 trading days.