Rates for conventional mortgages surged last month by the most in two decades, but financing costs for million-dollar homes are becoming a relative bargain. Deposit-rich banks needing to make loans are suppressing rates to compete for wealthier customers as home prices soar in expensive areas like Manhattan and San Francisco.

On average, the extra cost of 30-year fixed jumbo loans reached a six-year low of 0.16 percentage point last month, HSH.com reports. Bigger adjustable-rate mortgages with payments that can rise after five years ended last week 0.09 percentage point cheaper, the most since at least 1998.

‘‘Lately, our jumbos are either in line with conforming [regular mortgages] or better,’’ said Karen Mayfield, at BNP Paribas’s San Francisco-based Bank of the West unit. ‘‘Slowly but surely, the gap has closed in the past six months, and it’s really become much more obvious in the market over the past 30 days.’’

Jumbo mortgages are loans larger than those allowed in government-supported programs, currently as much as $729,750 for single-family properties in high-cost areas. For Fannie Mae and Freddie Mac loans with the lowest costs for borrowers using 20 percent down payments, the limits range from $417,000 to $625,500.

Bigger loans are getting relatively cheaper because they’re mostly put on banks’ balance sheets instead of packaged into securities that are sold to investors, said Paul Miller, an analyst at FBR Capital Markets.

Banks are seeking those loans because ‘‘there’s just not enough economic growth out there to create the other lending opportunities needed to support all the capital at these banks,’’ he said.

Mike and Kelly Guarascio, who are buying a four-bedroom house in Stratham, N.H., for $570,000, locked in a 4.25 percent rate with Wells Fargo on a 30-year fixed mortgage that was about an eighth of a percentage point cheaper than Fannie Mae and Freddie Mac loans.

They initially considered using a larger down payment to get below the jumbo limit because they thought it might save them money. That changed when the Federal Reserve signaled last month that it’s moving closer to reducing measures to stimulate the economy, which sent bond prices lower, causing the biggest losses in government-backed mortgage securities since 1994.

Conventional fixed-rate borrowing costs soared to the highest since July 2011, with average rates for 30-year mortgages rising last week to 4.46 percent from 3.93 percent — the biggest one-week jump since 1987, according to Freddie Mac surveys. The rate is up from 3.35 percent at the start of May.

At those rates, Jason Bonarrigo, a loan officer at Residential Mortgage Services , suggested the Guarascios take the jumbo option.

‘‘When you look at monthly payments, every little bit helps,’’ Guarascio said. The savings ‘‘make us feel better. If you look over the course of a year, if you save $100 or so a month it is probably a nice vacation or something.’’

Jumbo mortgage origination rose 15 percent to $54 billion in the first quarter from a year earlier and is on pace to hit $220 billion in 2013, the most since 2007, according to the newsletter Inside Mortgage Finance. New loans are still down from a peak of $650 billion a decade ago and were a fraction of the $433 billion in government-backed loans originated in the first quarter.

Banks are seeking to provide the loans after accumulating too much cash and bonds as a slow economy damped borrowing demand from consumers and companies and Americans sought the safety of bank accounts after pulling money from the stock market.

The difference between deposits at banks and their lending is at a record of almost $3.2 trillion, after averaging about $430 billion in the decade before the 2008 financial crisis, according to Federal Deposit Insurance Corp. data.

Wells Fargo’s website on July 1 said it was offering 30-year fixed-rate jumbo loans at 4.38 percent, lower than the 4.5 percent for conforming loans.

The same day, an application on JPMorgan’s website estimated a rate of 4.38 percent for a fixed-rate loan to a New Jersey home buyer with excellent credit putting 30 percent down to buy a $1 million home, compared with 4.5 percent for a similar individual buying a $200,000 property. A seven-year jumbo adjustable rate mortgage, or ARM, was offered at 3.25 percent, compared with 4.75 percent for the other.

‘‘It’s unusual to see jumbos priced below the conforming rate,’’ said Keith Gumbinger, vice president of Riverdale, N.J.-based HSH.com. ‘‘These are very valuable customers and also a very small group, so competition for them can be intense.’’

JPMorgan doesn’t tie its jumbo-mortgage pricing to the amount of its other products used by a borrower, but it likes the loans partly because of the relationships with affluent customers they can create or deepen, said Sean Kelley, chief financial officer of mortgage originations.

Vickee Adams, a Wells Fargo spokeswoman, declined to comment.

It’s especially unusual for fixed-rate jumbo loans to be cheaper than conventional loans. The extra cost peaked at as much as 1.8 percentage points higher in December 2008.

Wealthy borrowers are good candidates for adjustable-rate mortgages, which banks prefer because they can share the risk of rising rates with homeowners, said Anthony B. Sanders, an economics professor at George Mason University.

Banks have additional incentive to snag jumbo borrowers because rising rates are curbing opportunities to refinance their competitors’ mortgages. Refinancing applications tumbled 41.8 percent between a 2013 peak in May and the week ended June 21, according to data from the Mortgage Bankers Association.

At the same time, housing debt is looking like a safer bet, as delinquencies fall from record levels and after property prices started last year to recover following a five-year slump.

Bank appetite for jumbo mortgages contrasts with upheaval in the market for securities without government backing created out of the loans. Investors have been demanding higher yields as the Fed’s potential tapering off of stimulus measures raises concern that the debt will remain outstanding for longer than projected and prices on competing risky assets have plunged.

The gap between rates on traditional and jumbo loans has also narrowed since Fannie Mae and Freddie Mac increased how much they charge to insure bonds, according to Bank of the West’s Mayfield. Their regulator has been seeking to make private capital more competitive after taxpayers were forced to bail out the government-chartered companies in 2008.

Fannie Mae charged 54.4 basis points for its new guarantees on single-family debt in the first quarter, up from 28.9 a year earlier, according to the Washington-based company.

And banks have plenty more capacity for home loans.

‘‘The banks are awash in liquidity, and they are looking for ways to make good loans,’’ said David Hilder, an analyst at Drexel Hamilton in New York.