I buy both locally and online.
I’m semi-retired and we divide our time between a farm which is well and truly in the middle of nowhere (and is where I do most of my brewing), and a house in the largest city in the state (and 3 of the 4 adjacent states, as well). It’s 250 miles from the farm to the city.
In the city there is one dedicated HBS and an Ace Hardware which added a homebrewing section a couple of years ago. The LHBS is 20 minutes from my house; Ace is 5, 10 if I hit most of the red lights.
Since I started brewing, 8 years ago, I have purchased most of my ingredients and supplies from the LHBS and taking them to the farm. The store has been in business for about 25 years, is owned by a father and son, and is well-stocked with fresh ingredients (they supply several of the 8 local breweries which helps with turning over inventory quickly). The owners are knowledgeable and helpful and, quite honestly, a couple of fun guys just hang out and visit with. I’ve bought most of my equipment online, mostly from AIH and Kegconnection.
In the past year I’ve started buying more ingredients online simply because of price. The LHBS is charging $1.75-1.95/lb for base malts, $3+ for most specialty grains. Even buying base malts by the bag would cost about $15 more for 50lbs than buying 5 10lb bags from Morebeer with free shipping. Hops are $2-3/oz. The HB section of the hardware store doesn’t have the variety of ingredients that the dedicated store has and the prices aren’t any lower. I’d like to patronize the local guys more, especially the LHBS, but at some point one has to decide what fits the budget the best. I’ve been brewing a lot more since I started buying in bulk and spending about the same amount as I spent last year when I brewed fewer batches.
I’ve heard through the grapevine that the LHBS guys might be pulling the pin on maintaining a storefront and just warehouse customer orders for pickup. The time suck of having someone sit in the store all day to serve a handful of walk-ins is no longer worth it when the bulk orders are paying the bills. I’ll be in town in a couple of days; I’ll stop in and visit (and buy something).