Several deals -- including a Microsoft Corp. acquisition and a potential divestiture by General Electric Co. -- boosted interest for blue chips, along with upgrades of Intel Corp. and Verizon Corp.
A move by Chinese authorities to curb growth did little to dampen sentiment.
"There have been some concerns raised about economic growth," said Robert Pavlik, chief investment officer at Oaktree Asset Management, noting that some economists now expect U.S. growth to be revised down to 0.7% for the first quarter from 1.3% previously.
But "helping support the market is the continuation of the M&A and private equity deals," he said.
The Dow Jones Industrial Average gained 79 points to close at 13,556, a new record closing high. For the week, the Dow rallied 1.7%.
The S&P 500 index gained 10 points to close at 1,522, a six-and-a-half-year high and just 5 points short of its all-time high of 1,527, reached in March of 2000. For the week, the S&P rose 1.1%.
The Nasdaq Composite gained 19 points to 2,558. But it finished down 0.2% on the week.
Among blue chips, Microsoft dropped 1.5% after announcing it agreed to buy internet advertising firm aQuantive in a $6 billion deal. Microsoft is paying $66.50 a share. AQuantative shares skyrocketed 77% to $63.79.
The deal comes a day after rival WPP agreed to buy 24/7 Real Media, another Internet advertising firm.
Also on the Dow, General Electric advanced 1.2%. GE is close to a deal to sell its plastics division for nearly $11 billion to Saudi Basic Industries Corp., according to reports in The Wall Street Journal and The New York Times.
And Intel Corp. jumped 2.1% after Merrill Lynch upgraded the stock.
Verizon Communications gained 1%. The telecom firm was upgraded to buy from sell at Citigroup, which said near-term earnings risks have been minimized and earnings-per-share growth should override capital spending concerns.
Exxon Mobil Corp. gained 1.8% as crude oil advanced 8 cents to close at $64.94. It early rose above $65 a barrel amid expectations of strong demand for gasoline ahead of the summer driving season and continued tensions in Nigeria.
Trading volumes showed 1.6 billion shares exchanging hands on the New York Stock Exchange and 2.1 billion shares trading on the Nasdaq stock market. Advancing issues topped decliners by 5 to 3 on the NYSE, while decliners outpaced gainers by 9 to 5 on the Nasdaq.
M&A, buyouts fuel market
Mergers & Acquisitions and private-equity buyout activity, already running at a breakneck pace this year, has accelerated in recent weeks, with many investors citing it as the key engine of the market's rally.
Also on Friday, the Wall Street Journal reported that Royal Bank of Scotland and Bank of America are in talks to settle their dispute over who will buy ABN Amro's LaSalle.
Trump Entertainment jumped 15% after saying it's received indications of interest to buy the Atlantic City, N.J. company.
CapitalSource agreed to buy Nebraska lender TierOne in a $652 million cash-and-stock deal. TierOne shares jumped 26%.
And Clear Channel Communications agreed to back a new offer from Bain Capital and Thomas H. Lee Partners.
Cadbury Schweppes gained 2.2% after reports about interest in its U.S. soft drinks unit that's it put on the block.
On the economic front, the University of Michigan said its consumer sentiment index rose to 88.7 in May from 87.1 in April. The increase was above the consensus forecast of Wall Street economists who had expected sentiment to slip to 86.0.
Bonds dropped after the data, with the benchmark 10-year Treasury bond down 13/32 at 97 19/32 in pric, while its yield, which moves inversely, rose to 4.757%.
Meanwhile, the yen rose across the board after Chinese authorities hiked interest rates and widened the band in which the yuan can trade vs. the dollar.
Starting Saturday, the yuan can move 0.5% in either direction a day, against previous rules limiting the move to 0.3% a day. The more the yuan rises, the less competitive Chinese imports into the U.S. will be.
The Japanese yen, which frequently acts as a proxy for the yuan, rose against the dollar. But the U.S. currency advanced against the euro.
Crude-oil futures rose 8 cents to close at $64.94 a barrel amid continued concerns about gasoline supplies and tensions in Nigeria.
Gold also advanced along with crude oil. Gold futures rose $4.80 to $662.0 an ounce.
By Nick Godt