Jerry Derstein has until Monday to decide how to reinvest a five-year certificate of deposit that earned 5 percent interest at Harleysville Savings Bank.

If the 63-year-old Montgomery County resident doesn't act, the CD will automatically roll over for another five years at just 4.17 percent, compared with the bank's highest rate of 4.89 percent for 17 months.

"I'm going with the highest rate even though it's shorter term," Derstein said yesterday, though he knows it puts him at risk of having to renew sooner than he'd like at an even lower rate.

"It's a gamble. It really is," said Derstein, who lives in Franconia Township and works in the accounting department of a technology company.

The current environment for interest rates is frustrating for investors like Derstein, but it is also causing major headaches for bankers.

While banks have diversified their operations over the last decade to boost fee income, the core of their business model remains: Pay depositors a relatively low interest rate, and lend at a relatively high rate.

The difference between those two rates is the net interest margin, and the problem for banks is that the margin is getting smaller, as short-term rates have climbed and long-term rates have not.

When that happens, "it puts a crimp in banking profitability," said Greg McBride, senior financial analyst at Bankrate.com in North Palm Beach, Fla.

The average net interest margin for banks and thrifts traded on major exchanges fell to 3.62 percent in the first quarter from 3.78 percent in last year's first quarter, said John McCune, director of research at SNL Financial L.L.C., of Charlottesville, Va.

Quarterly results issued Monday by Prudential Bancorp Inc. of Pennsylvania illustrated the trend. The South Philadelphia bank's net interest margin fell from 2.93 percent to 2.74 percent. The average rate it paid on interest-bearing liabilities rose 69 basis points to 3.83 percent while the average interest rate it was receiving rose only 45 basis points.

Heather Wolf, a Merrill Lynch & Co. Inc. banking analyst, said Wednesday in a research report on mid- and small-cap regional banks that she expected the margin to keep going down for the remainder of the year, as depositors move money to higher-yielding accounts.

Bankers and financial experts attributed the unusually sustained period of short-term rates at or above long-term rates to the powerful combination of the Federal Reserve's maintenance of the Federal Funds target rate at 5.25 percent and the enormous influx of money into the United States from overseas.

"The Fed can do what it wants at the short end," but the globalization of capital markets means the Fed has less control over long-term rates, said David Wyss, chief economist at Standard & Poor's in New York.

Wyss said the net flow of money into the United States in 2006 was $1.1 trillion, with most of it going into bonds and other fixed-income instruments. That demand keeps yields on long-term bonds in check, preventing long-term rates on loans to businesses and consumers from rising much.

"Our borrowing customers are happier than our depositing customers," said Timothy Abell, chief operating officer at Firstrust Bank, a privately owned bank in Conshohocken.

Firstrust is offering its highest CD rate - 4.88 percent - at seven months, betting that short-term rates will come down later in the year, Abell said.

Exacerbating things for bankers is fierce competition for deposits, especially from relatively new banks. "They play a role in driving up the cost of deposits for every bank in the market," McCune said.

Kevin Kutcher, chief executive officer of three-year-old Liberty Bell Bank in Cherry Hill, said Liberty Bell was trying to attract deposits with a special deal for business owners.

The bank is offering to pay 6.05 percent interest on business owners' personal checking accounts up to $50,000, but only if they also have their commercial account - on which it is illegal for the bank to pay interest - at Liberty.

"Our average cost of funds will be lower because we have the business funds," Kutcher said.

Contact staff writer Harold Brubaker at 215-854-4651 or hbrubaker@phillynews.com.