Bank loan ETFs are sitting on gains for 2013 while diversified bond funds are in the red due to rising interest rates.

PowerShares Senior Loan Portfolio (NYSEArca: BKLN) is one of the best-selling ETFs this year with net inflows of about $3.3 billion, according to IndexUniverse. It is the largest bank loan ETF with assets of $4.8 billion.

BKLN and other bank loan ETFs have been popular with investors seeking yield and protection from rising rates. The funds have delivered on both fronts.

For example, BKLN is yielding more than 4%. In terms of performance, the bank loan ETF has delivered a year-to-date total return of 2.8%, compared with a loss of 2% for iShares Core Total US Bond Market ETF (NYSEArca: AGG), according to Morningstar data.

Bank loans “have tended to have low average default rates versus high-yield bonds, above-average yields, and very low duration (given that they pay floating rates), are negatively correlated to Treasury bonds, and have historically generated above-average returns in rising interest-rate environments,” writes Morningstar ETF analyst Timothy Strauts in a commentary posted Wednesday.

Other ETFs in the category include Highland/iBoxx Senior Loan ETF (NYSEArca: SNLN), irst Trust Senior Loan Fund (NasdaqGM: FTSL) and SPDR Blackstone/GSO Senior Loan ETF (NYSEArca: SRLN). [Bank Loan ETFs: Active or Passive?]

Investors have been “pouring money into bank-loan funds” as interest rates rise, Strauts notes. After dipping below 1.7% in early May, yields on 10-year Treasury notes have vaulted to around 2.6%.

“Rising rates have had very little effect on the price of bank loans, given that their duration tends to be very near [zero]. And given that the economy has continued to improve, the default rate within the sector over the past year has been just 1.4%,” the Morningstar analyst said.

Ownership of bank loans has changed in recent years after the financial crisis blew up many leveraged hedge funds. Retail investors are filling the void, he said.

“Bank-loan funds have received record inflows in 2013. Since the end of June, $33 billion has been invested in the category. The five largest monthly inflows on record occurred over the past five months. There is clearly tremendous investor interest in the sector,” Strauts wrote.

He thinks the broader ownership among retail investors is a positive development for the overall health of the bank loan market. “Under ‘new ownership’ small losses will be less likely to cause panicked selling in the retail market the way it did amongst hedge funds meeting margin calls,” Strauts added.

Meanwhile, the biggest risk facing the bank-loan sector is a U.S. recession, he said.