But now their support is dwindling. Some big investors are pruning their holdings. That is beginning to widen the cost of borrowing for Puerto Rico relative to other states and municipalities, which are benefiting from a big decline in borrowing costs. The interest rate its 30-year bonds now pay is about 2.5 percentage points higher than other municipal borrowers’, up from a difference of just 1.5 percentage points at the beginning of 2012, according to Municipal Market Data.

The possibility of a credit downgrade also hangs in the air, something that could lead to more selling.

“There is no specific event looming on the horizon,” said Alan Schankel, a managing director at Janney Capital Markets in Philadelphia. “But it’s a problem of immense magnitude, and it’s very challenging to sit here and see how they work their way out of it.”

Puerto Rico needs to be able to issue bonds at attractive rates to cover its short-term financing needs. Perhaps more important, it has to figure out how to salvage its retirement funds. After shortchanging them for years, it now has the weakest major public pension system in America.

The main fund, which serves about 250,000 government workers, past and present, is only 6 percent funded — a small percentage of what is considered the minimum needed for a marginally healthy pension plan — and could run out of money as soon as 2014. Another fund, for about 80,000 teachers, which is 20 percent funded, will last just a few years longer if nothing is done. Police officers and teachers in Puerto Rico have opted out of Social Security and rely entirely on their pensions.