These Walgreens window displays in Porter Square don’t quite fit the windows they’re in. (Photo: Marc Levy)

These Walgreens window displays in Porter Square didn’t quite fit the windows they were in. (Photos: Marc Levy)

The Walgreens in Porter Square is closing July 30, a company spokesman said.

The closing is part of a sweep of about 200 underperforming stores announced by the company in April and meant to save the chain about $1 billion, spokesman Phil Caruso said Thursday. The company, based in Deerfield, Ill., has more than 8,200 locations.

“It’s never easy to do anything like this,” Caruso said. “We do expect to place the majority of employees at other stores.”

There are three nearby – at 625 Massachusetts Ave., Central Square; and at 343 Broadway and 16 Beacon St. in Somerville – and upon the closing in Porter Square the prescriptions of its pharmacy customers will be sent automatically to whichever store is geographically nearest to the customer’s address on file, he said. Customers will get mail telling them of the change.

The two-story, 13,237-square-foot store opened in 2013, forcing out a Pier 1 Imports store that had been on a month-to-month lease with landlords KS Partners. Walgreen had done significant reconstruction of its square footage, adding an escalator to its second story, long emptied by the departure of a Blockbuster video store.

The store went 24-hours only weeks after opening to match the 24-hour CVS already open across the street.

The store went 24-hours only weeks after opening to match the 24-hour CVS already open across the street.

It is literally across the street from a 24-hour CVS at 36 White St. and less than a block from a 24-hour Star Market grocery store in the same plaza. For some of its first months in business, the Walgreens also operated an all-day schedule before eventually settling on opening at 7 a.m. and closing at 10 p.m. Its pharmacy operated even shorter hours.

Comments on stories about the direct competition between the two chains, which both have groceries, cosmetics and other notions in addition to pharmacies, was largely negative, although one Cambridge Day commenter called the coming Walgreens “a win for the mall and the area … I think the Walgreens will be a good addition and will bring some life to this half-empty shopping center. Yeah, CVS is a stone’s throw away, but it will be good to have some options, since that place is always crowded.”

At the Somerville Patch, though, a commenter called the move “bad for local small business and local economy, period.These robotic heartless, sentiment-less, money-hungry corporate businesses should not have been welcomed in the first place. We do not need more.” A user identified as Stephanie Toews Moeling said, “One big-box pharmacy peddling plastic Christmas gifts, cards and diapers is enough. How is it that the folks who make these choices have so little imagination?” And a user identified as Courtney O’Keefe agreed “it is bizarre that they will situate it near its direct competitor.”

While acknowledging the company chose to site a store directly across from an established competitor with the same offerings, Caruso said there were many factors that went into choosing locations. “We’re a company that believes in good competition,” he said.

But with three other nearby Walgreens locations, the area may have been saturated, he said.

A message was left Thursday with KS Partners, but the company did not immediately reply.

Across the street in the shopping plaza, real estate developer and manager Gravestar has a storefront left empty by a Radio Shack closing that resulted from the electronics chain seeking Chapter 11 bankruptcy protection.

Cambridge Day was alerted to the Walgreens closing by Ron Newman of the Davis Square LiveJournal, where commenters nearly universally identified the sense the store had always been doomed.