(Bloomberg News) U.S. state and city debt is set to extend its longest rally in five years as investors put to work a record wave of cash from bonds that are maturing or being refinanced.

The $3.7 trillion municipal market is set for a sixth straight quarterly gain, the longest streak since 2007, according to Bank of America Merrill Lynch data. The securities have returned 1.9 percent since March 31. Another three-month advance would make the rally the best in 11 years.

Local-government debt has joined Treasuries in benefiting from Europe's sovereign debt crisis and signs of slowing economic growth. Municipal yields are close to the lowest since the 1960s, spurring localities from Hawaii to Florida to refinance higher-cost borrowings at the fastest clip since at least 2007. At the same time, defaults are in decline as revenue rebounds from the recession that ended in 2009.

"This market has regained a lot of its semi-safe haven status in the minds of individual investors," said Chris Mauro, head U.S. muni strategist at RBC Capital Markets in New York. "The sky didn't fall in. We've had limited cases of defaults."

Investors are set to receive about $142 billion in the three months through July from maturing and refunded bonds, a historic amount, according to Citigroup Inc. The flood has prompted the biggest addition to municipal mutual funds in three years, helping depress borrowing costs.

Four Decades

Local-government yields are close to the lowest in a generation. Twenty-year general obligations yield 3.95 percent, compared with an average of 5.88 percent since 1961, according to a Bond Buyer index.

States and cities have already sold about $108 billion of bonds to refinance debt this year through June 27, the most for the period since at least 2007, data compiled by Bloomberg show. About 59 percent of issuance has been for refinancing, compared with an average of 40 percent for the previous five years.

The Massachusetts Port Authority, which operates the Boston-Logan International Airport, plans a refunding sale in the next two weeks, data compiled by Bloomberg show. Polk County, Iowa, and Pocahontas, Arkansas, also have refunding sales scheduled.

This week, RBC increased its estimate for total 2012 municipal issuance to $365 billion from $340 billion because of "abnormally high refunding," Mauro said. The supply jump probably won't boost yields because it's "just swapping new bonds for old bonds," he said.

$180 Billion

Citigroup estimates that new bond sales will trail principal and coupon payments to investors for a second straight year. Including issuance for new projects, municipalities have sold almost $180 billion this year, compared with about $99 billion in the same period of 2011, data compiled by Bloomberg show.

"Supply is actually up a lot this year, but when you drill into it, refunding supply is up even more," said Jamie Pagliocco, director of bond managers overseeing $30 billion of munis at Fidelity Investments in Merrimack, New Hampshire. "Coupons are being called away and you have to reinvest them in today's marketplace at a substantially different yield level."

This quarter, munis have trailed gains in Treasuries, the primary haven for investors as European leaders have struggled to resolve their debt crisis while U.S. job growth has slowed. Federal debt has earned about 3.2 percent since March 31, Bank of America data show.

Treasuries Lead

With Treasuries leading the fixed-income rally, the 10-year benchmark muni yields, at 1.94 percent, are about 120 percent of those on like-maturity federal debt, Bloomberg Valuation data show. The ratio, a gauge of relative value between the two asset classes, has been above 100 percent since mid-May, enhancing the appeal of munis for investors seeking tax-exempt income.

Investors have added $14.7 billion to municipal-bond mutual funds in 2012, the most for the period since 2009, Lipper US Fund Flows data show. That compares with $21 billion withdrawn over the same period last year, the most since at least 1992, amid speculation that local-government defaults would climb.

Instead, missed payments have dropped. Thirty-seven issuers have defaulted through June 26, compared with 57 in the same period of 2011, according to Municipal Market Advisors.

In a sign of improving fiscal health, state tax collections rose in the first three months of 2012 for the ninth straight quarter, according to the Nelson A. Rockefeller Institute of Government in Albany, New York.

Following are pending sales:

NEW YORK CITY TRANSITIONAL FINANCE AUTHORITY plans to offer $850 million of Building Aid Revenue Bonds next month, according to the city's Office of Management and Budget. The bonds are secured by state payments to help finance public-school buildings. Moody's Investors Service rates the credit Aa3, fourth-highest. (Added June 28)

MASSACHUSETTS PORT AUTHORITY is set to issue $285 million in revenue debt as soon as next week, according to an offering statement. About $120 million will be subject to the alternative minimum tax, according to the document. (Added June 28)