San Francisco CNN Business  — 

Walgreens plans to open full-service doctors’ offices in hundreds of its stores across the US during the next five years.

It’s part of a bigger effort by the drugstore chain to become a one-stop shop for health care.

Walgreen (WBA)s Boots Alliance is partnering with health care company VillageMD to create the 500 to 700 primary care clinics. During the next three years, Walgreen (WBA)s will invest $1 billion in VillageMD, including $250 million upfront, to assist the build-out efforts. The full investment would give Walgreen (WBA)s a 30% share of VillageMD.

Walgreens’ big bet on VillageMD marks another entrant into the growing concept of the “retail clinic.” Competitor CVS is leveraging its $70 billion acquisition of insurance company Aetna by building out 1,500 HealthHubs – featuring chronic-condition care services and health and wellness products – by the end of 2021. Walmart, the nation’s largest retailer, is starting to test out health clinics as well.

“What will the pharmacy experience look like in 2025?” asked Eric Percher, research analyst at health chare investment research firm Nephron, in a research note Wednesday. “We see bifurcation between the young and well who will increasingly turn to digital experiences and older populations managing chronic conditions who will increasingly engage with community sites of care.”

In-store clinics, such as the ones Walgreens plans to build, would appeal to older populations looking for easy access to health care, he said.

Walgreens’ clinics will open in at least 30 metro area markets during the next five years and then 20 more markets, said Morry Smulevitz, a Walgreens spokesperson. Walgreens has been testing out the concept in Texas with five in-store clinics in the Houston area.

Each clinic will occupy about 25% of an average Walgreens store, Smulevitz said.

In recent years, Walgreens has been shrinking the retail component of the store and adding offerings such as labs, eyeglass and hearing aid clinics, Jenny Craig centers and shipping offices to diversify and grow revenue.

“They’re going to keep building things within that store to make sure you’re coming back to that location,” Soo Romanoff, a Morningstar analyst who covers Walgreens, told CNN Business.

Walgreens currently dedicates a significant portion of its stores’ square-footage to retail products; however, those items account for roughly 25% of overall sales while pharmacy sales make up 75%.