Bank of America is purging branches, but many of its depositors appear to be staying put.

The Charlotte, N.C., company has sold more than 330 branches, trimming fixed costs as it invested in digital banking. The divestitures have provided several smaller banks with a low-cost way to add deposits and gain market share.

But there's a catch.

An increasing number B of A customers are declining to move their accounts, industry experts said. As a result, many small-town banks are gaining fewer deposits than what they originally expected to bring in.

In several recent branch sales, up to 40% of the deposits that existed at the announcement date did not go to the buyer at closing, according to company filings.

That's a higher rate than what typically occurs. While some deposits are likely fleeing to other banks, industry experts are convinced that B of A — in the midst of a technology push that features splashy upgrades to its mobile app — is keeping a larger percentage of its deposits. If so, it would reveal that many customers will stick with a tech-focused bank even if it lacks a physical location.

That seems to be the case with B of A's recent branch deal with TriCo Bancshares in Chico, Calif., said Tim O'Brien, an analyst at Sandler O'Neill. TriCo agreed in October to buy three branches, along with $245 million in deposits, but it only gained two-thirds of the deposits when the deal closed.

Many Bank of America customers didn't feel the need to switch banks, O'Brien said.

"Client choice and taste is evolving," O'Brien said. "What happened here is a manifestation of the execution" of B of A's tech strategy.

TriCo isn't the only branch acquirer to get fewer deposits at closing.

The $2.5 billion-asset Cascade Bancorp in Bend, Ore., agreed in October to buy branches with $707 million in deposits. As with TriCo's deal, nearly a third of the deposits stayed with B of A or went elsewhere.

Cascade executives expected a 20% runoff rate, said Tim Coffey, an analyst at FIG Partners.

Several other banks also agreed to buy B of A branches in recent months, only to lose 26% to 42% of the deposits.

Deposit retention isn't new for B of A branch deals, but it has increased. Two years earlier, Washington Federal in Seattle reported an 11% reduction in deposits between announcement and closing dates for a 23-branch deal with B of A.

Representatives for B of A and Cascade declined to comment. TriCo did not immediately respond to a request for comment.

The $2.1 trillion-asset Bank of America has set ambitious goals to make sure its customers never have to visit a branch, including plans to triple spending on its mobile app this year. Last year, the number of B of A customers using mobile banking rose 13%, to nearly 19 million.

"We've optimized our delivery network, reducing our financial centers, divesting certain markets and also expending our award-winning mobile capabilities and the customer base that uses that," Brian Moynihan, Bank of America's chairman and chief executive, said during a January conference call.

Recent branch deals also reveal how a growing percentage of the population regards branches as an unnecessary part of their banking experience, industry experts said.

In the last year, several surveys have highlighted rising consumer demand for high-tech, digital products. Last year, 43% of adults used their mobile phones for financial services, according to a recent survey by the Federal Reserve Board.

B of A is one of several big banks to capitalize on growing consumer demand for technology. Bigger institutions recently topped J.D. Power's consumer satisfaction survey for the first time ever, largely due to their high-tech offerings.

Citigroup, meanwhile, has also retained a large portion of relationships as it exits major markets such as Boston, Philadelphia, Dallas and Houston, largely by making them a key part of its digital strategy.

Banking with technology is "more responsive to the way people are really going to access their bank in the future," John Gerspach, Citi's chief financial officer, said during a January conference call.

Other dynamics could also play into B of A's retention, industry experts said. In many instances, B of A likely held deposits tied to larger clients that might have been more challenging for community banks to service. Other customers could be retail clients who have yet to transfer funds to a smaller bank.

Another factor could be the fact that Bank of America still has branches in most states.

Joe Adams, chief executive of FS Bancorp in Mountlake Terrace, Wash., just outside of Seattle, said he believes some B of A customers elected to stay put because they travel to states such as Arizona and Florida during his area's rainy season. FS Bancorp lost out on 30% of the deposits at the branches it bought; management had expected a 25% drop.

"I'm guessing there might be perceived convenience" having branches elsewhere, Adams said, adding that his $678 million-asset company has a range of online banking options.

While higher retention rates could make future branch deals less appealing for smaller institutions, some industry observers said they believe physical locations will still present opportunities for community banks to gain market share. In many instances, buyers have negotiated lower premiums that reflect a decline in the amount of deposits transferred.

"For a community bank, their lifeblood is a bricks-and-mortar branch," said Jeffrey Rulis, an analyst at D.A. Davidson. Compared to buying banks or building offices, branch deals remain "a cheaper way to get access to customers."