WPSlash

How to Set Different Minimum Delivery Amounts for Each Location in WooFood

If you’re using WooFood – the WooCommerce food delivery plugin, you may want to set different minimum order amounts depending on the location. This is especially useful for restaurants with multiple branches or different delivery zones, ensuring that delivery costs are covered efficiently.

In this guide, we’ll show you how to use a simple WooCommerce hook to set custom minimum delivery amounts per location using a code snippet in your WordPress child theme’s functions.php file.


Why Set a Minimum Delivery Amount Per Location?

✔ Custom pricing for different areas – Prevents low-value orders in high-cost delivery zones.
✔ Supports multiple store locations – Assign a different minimum order amount for each branch.
✔ Ensures profitability – Encourages larger orders for more distant locations.
✔ Seamless WooCommerce integration – Works perfectly with the WooFood plugin.

This setup is ideal for restaurant chains, multi-location businesses, and WooCommerce stores that offer delivery to different regions.


How to Set Different Minimum Delivery Amounts Per Location in WooFood

To customize the minimum order amount for each store location, add the following PHP snippet to your theme’s functions.php file:

<?php
add_action( 'woocommerce_checkout_process', 'woofood_custom_hook_minimum_per_store', 9999999 );
 function woofood_custom_hook_minimum_per_store() {
   global $woocommerce;



    if (isset($_POST["extra_store_name"])) {

      //35 is the store id //

    if ($_POST["extra_store_name"] == "35")
    {
          wc_add_notice( 
                sprintf(  __( 'You must have an order with a minimum of %s to place your order, your current order total is %s.', 'woofood-plugin' ) , 
                    wc_price( 20 ), 
                    wc_price( WC()->cart->subtotal )
                ), 'error' 
            );

    }
          //34 is the store id //

    else if($_POST["extra_store_name"] == "34")
    {
         wc_add_notice( 
                sprintf(  __( 'You must have an order with a minimum of %s to place your order, your current order total is %s.', 'woofood-plugin' ) , 
                    wc_price( 25 ), 
                    wc_price( WC()->cart->subtotal )
                ), 'error' 
            );
    }

      

    }
}

?>

How This Code Works

✅ The woocommerce_checkout_process hook ensures the minimum order validation happens during checkout.
✅ The function woofood_custom_hook_minimum_per_store() checks the store ID selected by the customer.
✅ Different minimum order amounts are applied based on the store location.
✅ If the customer’s order subtotal is below the required minimum, an error message prevents checkout.


Best Practices for Implementing Location-Based Minimum Delivery Amounts

🔹 Ensure your store locations are properly configured in WooFood.
🔹 Modify store IDs and minimum order values to match your restaurant’s requirements.
🔹 Test the code in a staging environment before deploying it to your live site.
🔹 Combine this feature with delivery zone-based pricing for more accurate delivery cost control.


Looking for a Complete WooCommerce Food Delivery Solution?

If you’re running a restaurant or food delivery business with multiple locations, you need a robust WooCommerce food ordering plugin that supports:

✅ Custom delivery pricing per location
✅ Minimum order restrictions based on delivery zones
✅ Pickup and delivery order management
✅ Real-time order processing

With WooFood – WooCommerce Food Delivery Plugin, you can fully automate your restaurant’s online ordering system, optimize the checkout process, and increase revenue with custom pricing strategies.

🚀 Upgrade Your WooCommerce Food Ordering System Today!

👉 Get WooFood here and take your restaurant website to the next level!

Leave a Comment

Your email address will not be published. Required fields are marked *

Related Articles

Tutorials

How to Set Up SMS and WhatsApp Order Notifications for Your WooCommerce Restaurant (2026)

Why SMS and WhatsApp Notifications Matter for Restaurant Orders A customer places an order on your <a href="https://www.wpslash.com/how-to-set-up-real-time-order-tracking-for-your-woocommerce-restaurant-website-2025-2/" title="How to Set Up Real-Time Order Tracking for Your <a href="https://www.wpslash.com/how-to-set-up-catering-and-large-group-orders-on-your-woocommerce-restaurant-website-2025/" title="How to Set Up Catering and Large Group Orders on Your WooCommerce Restaurant Website (2025)”>WooCommerce Restaurant Website (2025)”>restaurant website at 7:15 PM during the Friday rush. […]
May 3, 2026
Tutorials

How to Set Up Real-Time Order Tracking for Your WooCommerce Restaurant Website (2026)

Why Real-Time Order Tracking Matters for Restaurant Websites Picture this: a hungry customer places an order on your <a href="https://www.wpslash.com/how-to-build-a-customer-loyalty-program-for-your-wordpress-restaurant-website-2025/" title="How to Build a Customer Loyalty Program for Your <a href="https://www.wpslash.com/how-to-connect-your-wordpress-restaurant-website-to-doordash-uber-eats-grubhub-2025/" title="How to Connect Your WordPress <a href="https://www.wpslash.com/how-to-rank-your-restaurant-website-on-google-local-seo-for-wordpress-2025/" title="How to Rank Your Restaurant Website on Google: Local SEO for WordPress (2025)”>Restaurant Website to DoorDash, Uber […]
May 3, 2026
Tutorials

How to Set Up Catering and Large Group Orders on Your WooCommerce Restaurant Website (2026)

Why Catering and Large Group Orders Matter for Restaurant Revenue Most restaurant owners pour energy into optimizing their dine-in experience and individual delivery orders while overlooking a revenue channel that can transform their bottom line: catering. A single corporate lunch order for 30 people can equal what your dining room generates in an entire slow […]
May 2, 2026