PurposeAs ecommerce becomes more prevalent, traditional brick-and-mortar retailers such as warehouse clubs (WCs) face the challenging task of maintaining and growing their customer base. This study aims to unravel the combined impact of retail agglomeration and ecommerce activities on consumer foot traffic (also referred to as “footprint”) at WC stores, placing an emphasis on the locational strategies adopted by WCs in this evolving retail landscape.Design/methodology/approachMobile-based customer foot traffic data for Costco, a major U.S. WC chain, is sourced for our analysis. We use Principal Component Analysis (PCA) to identify dimensions of general merchandise (GM) and narrow-range merchandise (NM) retail agglomeration. Two-stage least squares (2SLS) regressions are used to explore how the intensity of ecommerce activities and WC locational choices within retail agglomerations impact WC foot traffic.FindingsOur analysis highlights a notable decline in WC store visits attributable to both GM and NM ecommerce activities, with GM ecommerce presenting a more significant competitive challenge to WCs. Regarding retail agglomerations, proximity to GM clusters that include a diverse range of supercenters, department stores, and club stores, is associated with an increase in WC customer visits within their vicinity. In contrast, the influence of NM agglomerations is mixed; clusters adjacent to grocery stores lead to higher WC customer traffic compared to those focused on other specialized stores. These findings underscore the strategic importance of location in mitigating the adverse effects of ecommerce competition. Additionally, our study uncovers intricate dynamics between GM and NM retail clusters and ecommerce activities, demonstrating varied impacts on WC customer footprint.Research limitations/implicationsAccess to customer footprint data illustrates the potential of this data source for retail decision making and researchers. Our analysis is limited to one chain, notably Costco.Practical implicationsOur findings underscore the need for retailers to adeptly navigate the evolving retail landscape, including the confluence between physical and digital retail environments, to secure future success. In particular, our results emphasize the benefits of locating stores within mixed retail agglomerations and underline the need to consider the broader retail landscape in location decisions.Social implicationsThe rise of ecommerce in the U.S. has reshaped consumer behavior and altered local shopping districts’ communal dynamics. This change may spur policy interventions to help physical stores compete with online retailers, emphasizing the importance of retail diversity and community-centric environments to sustain communal retail interactions amidst digital advancements.Originality/valueThe paper makes use of a unique dataset to provide a first assessment of the combined effects of retail agglomeration and ecommerce activities on consumer foot traffic for WC retailers. Thus, this paper provides insights into the impacts on consumer shopping behavior from the dynamic interactions between physical retail clusters and online shopping behaviors.