Amazon’s pending deal for grocery chain Whole Foods Market, which has several North Bay locations, is a high-profile reminder of the hundreds of millions of local dollars going into online sales that aren’t going to locally based businesses. But there’s an ambitious effort in the region to equip brick-and-mortar businesses to make a bigger play in the digital world.

Sonoma County GoLocal Cooperative, a buy-local network of about 400 businesses, is gearing up to test later this year a mobile app-based system that would allow local consumers to search for in-stock products to purchase on location or by delivery.

That may not seem revolutionary at a time when more online product searches are started via Amazon than search engines such as Google, and when large retailers offer online shoppers options such as ship to store, in-store pickup and home delivery. But the level of sophistication that goes into creating and maintaining such a system with features today’s consumers expect is daunting to recreate at the local level, say leaders of local business groups.

“We’ve been looking at for a couple of years how to stem some of this home-delivery business, which is essentially what all online shopping is, the convenience of having things delivered to your house,” said Terry Garrett, co-managing member of Sustaining Technologies, a Santa Rosa-based economic-development marketing firm. He co-manages Sonoma County GoLocal Cooperative and is interim manager of the Sonoma County Growers Alliance cannabis trade group.

Taxable sales totaled $26.0 billion in Sonoma, Solano, Marin, Napa, Mendocino and Lake counties in 2015, the most recent data available from the California Department of Finance. The percentage of online to instore sales has increased from 7.8 percent in the first quarter of 2016 to 8.5 percent in the first quarter of this year, according to the National Retail Federation’s analysis of Census Bureau figures. That would amount to more than $2 billion a year for North Bay counties.

In Sonoma County alone, total “retail leakage” is estimated to be $1 billion annually, according to ESRI figures Garrett commissioned plus Census data. The county’s online leakage could be around $700 million annually, based on 8 percent share.

“Retail leakage” is economics-speak for spending by residents of an area that’s higher than what’s going to local businesses. It includes purchases by residents from businesses outside a given area, whether done at a physical storefront, directly from a business by phone or online, or via virtual superstores such as Amazon.

The Seattle-based mega e-tailer Amazon is estimated to command as much as half of online sales in the U.S.

“Every bite that comes out of our local retailers, we have a motivation for how to stop that,” Garrett said.

The challenge has come in recreating with local resources some of the functionality from the two-decade head start Amazon has had on e-commerce. The GoLocal approach is starting with the retail type that many of the big players have been tackling: grocery and food. That’s what analysts guess is Amazon’s goal with Whole Foods, which itself has been partnering with grocery delivery vendors such as Instacart.

“People make purchases every day, and the likelihood of them being inconvenienced by going out of their house to get something offers the greatest market opportunity,” Garrett said.

But for local grocers, getting their inventory online is complex. Garrett and his team have built the software and are moving into testing this fall with one undisclosed grocer member of GoLocal and just 1,200 items, or shelf-keeping units (SKUs). That means uploading information and photos for each.

The second hurdle will be making that inventory “dynamic.”

“You don’t want to have something that says something is available, and someone orders it, only to find out later that it’s not there,” Garrett said. “If you’re not in that (online) business, you’re not worrying about that. You’re, of course, ordering inventory, but you’re not saying it has to be there because I’ve promised to sell it. If you walk into a store and ask for it, they can say they don’t have it but will order it and have it next week.”

In the online-shopping world, the expectation is that the product said to be in stock actually is and can be delivered quickly, so the excuse that the item isn’t available after ordering it is less-tolerated, he said.

The GoLocal vision is to create a portal for consumers to shop online from a number of the organization’s members. If, say, 20 of the 400 members were identified as candidates for this, the complexity of ­setting up and maintaining a dynamic, interactive shopping experience multiplies, Garrett said.

“Then they have to agree to monitor it every day,” he said. “For the big guys, they have inventory-management systems that are sophisticated enough to report that. The local companies are just not that sophisticated, where their systems can talk to the software that is managing the (shopping portal) system, so it requires human interaction to make sure it is working properly.”

Amazon has set the bar high for retailers big and small to compete on an oft-cited strategic business framework: performance superiority, customer intimacy and operational excellence, Garrett said.

“You have be a leader in one of those three, and you have to hit fair-market value on the other two,” he said. “Amazon probably is one of the only companies I’ve looked at in the retail consumer field that has hit on two of those, and that is why they have crushed it. It is a huge hurdle for 20 local companies to work together and operate on some level on two of those levels.”

“Customer intimacy” includes product suggestions based on past purchases. “Operational excellence” covers one-click ordering, next-day order fulfillment and accurate orders.

But small brick-and-mortar retailers can solve the dynamic-inventory challenge of the move into the online world by integrating accounting, inventory, point-of-sale and e-commerce systems, according to Kate Schneider, co-founder and president of Santa Rosa-based ZDCA Design & Development. The firm creates print and digital marketing materials, building e-commerce websites as part of an omnichannel strategy.

Since 2013, the firm has been integrating such sites with Shopify, an 11-year-old Canada-based company that provides tools to over a half-million small- and medium-sized businesses that sell online or on site.

Recently, ZDCA was named a Shopify Plus expert, one of three in the Bay Area and 100 globally able to work with high-growth enterprise clients. Other providers of point-of-sale hardware and software include Square and payment processors such as San Rafael’s Central Payment and PayPal.

“The key to success is to integrate,” Schneider said.

That means getting POS systems to communicate with accounting and inventory software.

The best case is that data handoff is handled automatically through existing or custom-built data interchange, but for small businesses it often takes an employee to import data from the POS then export an updated spreadsheet in such a way that the e-commerce software can update the website, Schneider said.

ZDCA is building an online store for Rileystreet Art Supply, which started in Santa Rosa 15 years ago and expanded to San Rafael six years back. Such a digistore allows small retailers to dive into Facebook and Google shopping arenas, though merchants can get into Fulfillment by Amazon by uploading photos and data directly there.

Jeff Quackenbush (jquackenbush@busjrnl.com, 707-521-4256) covers the wine business and commercial construction and real estate.