The Dow closed at a record Monday as investors cheered the weekend passage of the Senate version of a sweeping overhaul of the U.S. tax code. However, the S&P 500 and the Nasdaq finished lower as large-capitalization technology names took a beating.

What are stocks doing?

The Dow Jones Industrial Average DJIA, +0.51% added 58.46 points, or 0.2%, to finish at 24,290.05, closing well off its intraday high. The S&P 500 SPX, +1.05% which had traded higher for most of the session, lost grip on positive territory late in the session. The large-cap index shed 2.78 points, or 0.1%, to end at 2,639.44 while the Nasdaq Composite Index COMP, +1.71% fell 72.22 points, or 1.1%, to 6,775.37, its losses deepening near the close.

The Russell 2000 index RUT, +0.78% of small companies shed 0.3% to 1,532.41 after hitting an intraday record.

Financial stocks hit a 10-year high earlier and were among the biggest winners, up 1.6%. The sector saw its fifth straight daily increase. Among the notable gainers, Bank of America Corp. BAC, -2.16% rallied 3.4% while JPMorgan Chase & Co. JPM, -1.09% was up 2.1%.

Notable tech losers included Apple Inc. AAPL, +1.57% which dropped 0.7% while Facebook Inc. FB, +2.66% fell 2.1%, Microsoft Corp. MSFT, +2.40% slid 3.8% and Alphabet Inc. GOOGL, +2.07% —the parent company of Google—slid 1.3%. Other major internet names were also lower, including Amazon.com AMZN, +5.69% , which fell 2.4%, and Netflix NFLX, +0.78% which declined 1.5%.

Facebook, Amazon, Netflix, and Alphabet are among the components of the so-called group of “FAANG” stocks, which have been among the market’s biggest leaders this year, although portfolio managers have been trimming their allocation to them.

On Friday, markets saw volatile trade after news about former national security adviser Michael Flynn triggered political uncertainty.

Further developments of this type could add more volatility to markets, even though investors said the issue wouldn’t have a direct impact on corporate profits or the pace of economic growth—the main drivers of the equity market.

Read:Here’s why the stock-market rally is unlikely to be derailed by Michael Flynn

Also see: Flynn who? For the stock market, it’s all about tax cuts and the Santa rally

What’s driving the market?

Progress on the Republican tax plan was in the spotlight for Monday, while investors continued to watch for news of the special counsel’s probe of U.S. President Donald Trump’s election campaign.

Early Saturday, the Senate passed the Republican-sponsored tax reform proposal almost entirely along party lines, which being viewed as a key victory for U.S. President Donald Trump.

Read:Trump celebrates tax-bill victory as opponents vent their fury via #TaxScamBill

Hopes that the Trump administration and Republicans would usher in a business-friendly tax overhaul have been cited as a driver for the stock market’s record-setting streak over the past year. The House and Senate now must agree on a single tax bill before it can be sent to Trump to sign.

J.P. Morgan forecast that the S&P 500 would hit 2,800 by early 2018—a level representing upside of 6%—on tax reform, adding that it had been about 50% priced into shares. Last week, the Wells Fargo Investment Institute raised its target for the benchmark index, citing optimism about taxes.

What are strategists saying?

“Getting the tax plan done will still be a challenge, but it doesn’t seem as impossible as it once did, and now there’s optimism that it could happen before the end of the year, which means it could be made retroactive and change the liability for companies and individuals for this year as well as next, which would be a positive,” said Randy Frederick, vice president of trading and derivatives for Charles Schwab.

About the political situation, Frederick said that Friday’s decline represented “an emotional reaction that was way overblown.” He added that “this issue is out there now, and as more stories associated with it come out, the market will likely have pullbacks on the uncertainty, though this isn’t significant enough to derail a bull market that is rising on fundamentals.”

See:It’s rare for the Dow to have ramped up like this—here’s what typically happens next

“The cornerstone of the current tax proposal is a decrease in the corporate tax rate, with which the U.S. would move closer to its developed market peers. Corporations with relatively high effective tax rates will likely enjoy materially lower tax bills should the cuts pass, so look to publicly traded equities within this class as a barometer for the probability of passage,” wrote Jason Pride, director of investment strategy at Glenmede, in a note to investors.

What stocks are active?

Shares of Aetna Inc. US:AET fell 1.4% after CVS Health Corp. CVS, -1.24% agreed to buy the U.S.’s third-largest health insurer for about $69 billion in cash and stock. CVS fell 4.6%.

CVS to acquire health insurer Aetna

Digital Power Corp. DPW, +2.87% jumped 91% after the company said its Coolisys Technologies unit launched a line of power systems for cryptocurrency mining.

Shares of General Cable Corp. US:BGC soared 35% after Italy’s cable maker Prysmian SpA PRY, +1.28% said it would buy the cable manufacturer in a deal that values it at around $3 billion.

What are data saying about the economy?

U.S. factory orders fell 0.1% in October largely because of fewer bookings for passenger planes, cars and trucks, the government said Monday.

Investors will get several big pieces of economic data this week, including the nonfarm-payroll report on Friday.

Read:Don’t expect strong U.S. hiring to keep up in 2018

What are other markets doing?

Asian markets finished mixed, with Hong Kong’s Hang Seng Index HSI, +0.15% rising after a string of consecutive losses. But other regional gauges, such as the Nikkei 225 index NIK, -0.05% , came under pressure. European stocks SXXP, +0.20% were higher across the board with the German DAX 30 index DAX, +0.41% surging by the most in a month, boosted by news of U.S. tax-plan progress.

Oil prices fell on Monday, with crude for January US:CLF8 down more than 1%. The ICE Dollar index DXY, +0.13% was up 0.3% while gold US:GCG8 settled lower.

Bitcoin BTCUSD, -0.51% came close to the $12,000 level in Asian trading hours on Monday, but has pulled back to last trade around $11,516.

Barbara Kollmeyer contributed to this article.