How to block a delivery method for a USA state if cart contains a specific product?
Step 1. Please create a Shipping Restriction rule by navigating to the Magento Admin Panel → Sales → Shipping Restrictions section and clicking the Add Rule button.
Step 2. Make sure to select the shipping method that will be restricted from the Restrict Shipping Carriers and Methods dropdown. You can choose a whole carrier or a specific shipping option within the methods of the carrier:
Step 3. If you would like a message to be displayed instead of the restricted delivery option, please set the Show Restriction Message option to Yes and add your custom message to the corresponding field:
Step 4. Let’s move on to specifying the state which will be restricted from delivery if at least one product from the list of SKUs is in the cart. Add the requirements that should be met for the rule to get applied in the Conditions section like so:
Here is how the blocked shipping method is going to look on the frontend when all of the restriction conditions are met:
Related Articles
How to configure the Free Shipping option for the order containing a specific product in case cart subtotal reaches a certain threshold?
As a rule, the Free Shipping delivery option can be configured using the default Magento 2 functionality, in case there are no complex conditions under which it should appear. For example, if you would like to provide free shipping for orders that ...
How can I restrict a particular shipping method with the Shipping Rules module?
Shipping Rules extension was created to overwrite the rates of the available shipping methods, and it cannot restrict shipping carriers/methods. In case you need to block any shipping method and hide it, you may consider using our Shipping ...
How to configure a Shipping Restriction based on postcodes?
There are several ways to configure a Shipping Restriction that will block a certain delivery method based on postcodes. Option #1 If you are using multiple single postcodes or ranges, one of the methods to configure a postcode-based Shipping ...
Why isn't the shipping method displayed for the cart that contains products with different shipping types?
In case your shipping behavior is based on offering different shipping rates for different shipping types, note that, for the shipping method to be For example, there are three shipping types on the instance: light, medium & heavy. It means that the ...
How do I specify estimated delivery time in the shipping method name?
The specified delivery date/time is shown in shipping method's name for informational purposes only to let customers know how long they should wait for the order to arrive. Shipping Table Rates extension is unable to provide the options of delivery ...