Discuss and resolve questions on Liquid, JavaScript, themes, sales channels, and site speed enhancements.
Is there a way to get your online store to sort by location if you have multiple locations set up?
We have a second store opening in a city and we are wanting customers to be able to essentially look at what's stocked at the store that's closest to them rather than looking at everything offered in both stores within the city. I figured this would be an obvious filter to have if you're allowing multiple locations but apparently not as I can't seem to find anything at all talking about this.
Hello,
So as far as I know, there are not any location filters, but there is a solution that comes to my mind. If you are using the free Shopify App, called "Search and Discovery, you could set up a custom filter (in this situation store_location), by creating a store_location metafiled. Then you could add it as a custom filter inside the app. Alternatively, if you don't use this or any app, you could also accomplish this by tweaking the code a little bit.
You can implement the solution from @andrija_obradov, which is pretty smart, but then you'll have to use some other app to sync the values of your locations with that specific metafield.
We were going to do this for one of our clients in the past, and from what I recall there was no simple way to set it up. You'll need a developer that knows what they're doing in order to create a custom switch to show/hide products based on their availability in different locations.
Shopify and our financial partners regularly review and update verification requiremen...
By Jacqui Mar 14, 2025Unlock the potential of marketing on your business growth with Shopify Academy's late...
By Shopify Mar 12, 2025Learn how to increase conversion rates in every stage of the customer journey by enroll...
By Shopify Mar 5, 2025