Case study
Local delivery system for WooCommerce
Rules-based local delivery that matched real cart composition, distance, and how the business fulfilled orders
Overview
A premium nursery retailer needed a better way to support local delivery inside an existing WooCommerce store. The problem was more complex than assigning a flat shipping fee. Delivery eligibility depended on the actual makeup of the cart, including product size, weight, cubic volume, maximum dimensions, and delivery distance from the selected store. The solution also needed to work inside an established WordPress environment and respect real budget constraints.
Instead of forcing the client into an expensive custom logistics platform, I designed and built a rules-based local delivery system directly inside WooCommerce. The result was a practical, maintainable solution that made delivery pricing more accurate, improved the customer workflow, and better reflected how the business actually fulfilled orders.
The challenge
This was much more involved than adding a standard shipping method.
The delivery workflow needed to evaluate multiple factors at once. Products had to be assigned to delivery tiers, carts had to be checked against thresholds for total volume, total weight, maximum item dimensions, and per-item weight limits, and pricing needed to respond to delivery distance. The system also had to support pickup versus delivery selection, handle ineligible items clearly, and preserve that fulfillment state from cart through checkout.
On top of the pricing logic, the customer experience needed to be clear and guided. If delivery was selected, the interface had to reveal the right fields, collect the required information, and explain when a cart was not eligible instead of failing in a confusing way.
The solution
I built a custom local delivery engine inside WooCommerce that evaluated cart eligibility and calculated delivery pricing based on business rules tailored to the retailer’s fulfillment model.
At the product level, shipping classes were used to map items to delivery tiers such as small, large, XL, and huge. The cart was then evaluated using configurable thresholds for volume, weight, maximum dimensions, and per-unit product weight. Pricing was driven by distance-based brackets and minimum-charge rules so the quote better matched real fulfillment costs.
On the front end, pickup remained the default fulfillment option. When a customer selected local delivery, the cart revealed delivery-specific fields and an AJAX-powered pricing summary. Successful quotes were stored in session data and carried through to checkout, where address changes could trigger re-quoting automatically. Validation only enforced delivery-specific requirements, such as phone number and SMS consent, when delivery was active, which kept the checkout flow aligned with the selected fulfillment method.
On the admin side, the system stored detailed delivery metadata with the order, surfaced that information on the order screen, and sent store-specific notification emails when an order moved into processing. I also added duplicate-notification protection to make the workflow more dependable for staff.
My role
I handled the technical implementation and helped shape how the delivery workflow worked in practice, including pricing logic, eligibility rules, fulfillment selection behavior, session persistence, distance-based quoting, admin order data, and fulfillment notifications. I also structured the system to be configurable and maintainable so it could continue to evolve as business needs changed.
Outcome
The finished solution gave the retailer a local delivery workflow that was much closer to how the business actually operated than a standard flat-rate shipping setup. Customers could get more accurate delivery pricing, staff had clearer order data, and the business had a flexible framework it could continue refining over time.
Just as importantly, it solved a fairly complex fulfillment problem without requiring a much larger rebuild. It fit inside the existing WooCommerce environment, respected budget constraints, and turned a difficult operational requirement into a working system that was understandable for both customers and staff.