NEW YORK (Reuters) - Wall Street’s three major indexes rose on Monday, led by a rally in tech stocks, pushing the Nasdaq to a record closing high as investors bet on a continuation of strong economic growth, while falling oil prices weighed on the energy sector.

Apple AAPL.O shares rose to their highest ever due to investor bets on its annual developers conference and Microsoft MSFT.O impressed with an acquisition, pushing the S&P 500 technology index .SPLRCT to a record high, while Amazon.com AMZN.O led consumer stocks higher.

Better-than-expected U.S. jobs data for May was still key to investor optimism as traders turned their focus away from recent trade war fears.

“There’s momentum from Friday’s job report that’s spilled into Monday’s trading and helped propel stocks higher,” said Kristina Hooper, chief global market strategist at Invesco in New York.

However, while impressed “to see a jobs report so strong late in an economic expansion,” Hooper worried about the U.S. government’s announcement last week of steel and aluminum tariffs for Europe, Canada and Mexico, which ended a two-month exemption.

“The jobs report is looking in the rear-view mirror while the protectionist actions last week will impact the future,” she said. “Investors may be caught off guard if there is a negative impact to economic growth this year from protectionism.”

The Dow Jones Industrial Average .DJI rose 178.48 points, or 0.72 percent, to 24,813.69, the S&P 500 .SPX gained 12.25 points, or 0.45 percent, to 2,746.87.

The Nasdaq Composite .IXIC added 52.13 points, or 0.69 percent, to reach 7,606.46, a record closing high.

The S&P 500’s technology sector was the benchmark index’s biggest boost with a 0.8 percent gain.

A trader works on the floor of the New York Stock Exchange shortly after the opening bell in New York, U.S., June 4, 2018. REUTERS/Lucas Jackson

Apple unveiled its latest operating system iOS 12 at the conference and after paring some gains in the afternoon, it closed up 0.8 percent.

Along with the jobs report, Kim Forrest, senior portfolio manager at Fort Pitt Capital Group in Pittsburgh, also cited Apple’s developer conference and Microsoft’s $7.5 billion deal to buy privately held coding website GitHub Inc as key drivers on Monday.

The consumer discretionary index .SPLRCD was the biggest percentage gainer of the S&P's 11 sectors, with a 1.1 percent rise, while the energy sector .SPNY was its biggest loser with a 0.9 percent drop as oil prices fell on worries about growing U.S. production. [O/R]

As well as the jobs report, Invesco’s Hooper said falling oil prices were helping sentiment around the consumer sector.

The Nasdaq Biotechnology Index .NBI underperformed the broader market with a 0.7 percent decline as shares of cancer-focused companies moved after presentations at the American Society of Clinical Oncology's meeting.

Nektar Therapeutics NKTR.O tumbled 41.8 percent and weighed on the index after mixed results from its experimental cancer drug with Bristol-Myers Squibb's BMY.N Opdivo disappointed investors.

Bristol-Myers Squibb ended 3.2 percent lower.

Merck MRK.N, however, gained about 2.4 percent after latest data showed its cancer drug Keytruda improved survival as a stand-alone treatment for a type of lung cancer.

Boeing BA.N rose 1.1 percent, the biggest boost to the Dow, after the planemaker said it would partner with French aerospace firm Safran SA SAF.PA to make and service aircraft parts.

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

The S&P 500 posted 46 new 52-week highs and five new lows; the Nasdaq Composite recorded 228 new highs and 44 new lows.

Volume on U.S. exchanges was 6.5 billion shares, compared with the 6.6 billion average for the last 20 sessions.