NEW YORK (Reuters) - The Dow and S&P 500 rose on Thursday to close at record highs as health insurers gained after the Trump administration scrapped a plan designed to rein in prescription drug prices, while financial shares climbed with bond yields.

A 5.5% gain in UnitedHealth Group Inc UNH.N helped the Dow close above 27,000 points for the first time. Cigna Corp CI.N surged 9.2%.

The abandoned proposal would have required health insurers to pass on billions of dollars in rebates they receive from drugmakers to Medicare patients.

On the flip side, drugmakers such as Merck & Co Inc MRK.N and Pfizer Inc PFE.N dropped following the news, and the Nasdaq biotech index .NBI was down 1.5%. Merck ended down 4.5% while Pfizer was down 2.5%. The S&P 500 healthcare index .SPXHC ended flat.

The S&P 500 traded above 3,000 for a second day in a row but again failed to close above that milestone, suggesting investor cautiousness.

“The fact that it has not been able to get through it and stay above that level has been a big psychological negative,” said Michael James, managing director of equity trading at Wedbush Securities in Los Angeles.

Helping to support stocks were comments from Federal Reserve Chairman Jerome Powell, which supported investor expectations for an interest-rate cut.

In his first day of testimony before Congress on Wednesday, Powell confirmed the U.S. economy was still under threat from disappointing factory activity, tame inflation and a simmering trade war and said the Fed stood ready to “act as appropriate.” Powell testified before the Senate Banking Committee on Thursday.

U.S. benchmark bond yields rose, and the S&P 500 financial index .SPSY gained 0.6%.

The Dow Jones Industrial Average .DJI rose 227.88 points, or 0.85%, to 27,088.08, the S&P 500 .SPX gained 6.84 points, or 0.23%, to 2,999.91 and the Nasdaq Composite .IXIC dropped 6.49 points, or 0.08%, to 8,196.04.

Iron Mountain IRM.N slumped after Bank of America Merrill Lynch downgraded the document storage company's shares to "underperform," citing recent declines in recycled paper pricing.

A Labor Department report showed U.S. underlying consumer prices rose by the most in nearly 1-1/2 years in June, but that was unlikely to change expectations the Fed would cut rates this month.

Declining issues outnumbered advancing ones on the NYSE by a 1.04-to-1 ratio; on Nasdaq, a 1.25-to-1 ratio favored decliners.

The S&P 500 posted 48 new 52-week highs and 4 new lows; the Nasdaq Composite recorded 77 new highs and 54 new lows.

Volume on U.S. exchanges was 6.17 billion shares.