Hello Magento Friends,

Today I will be discussing on How to Remove/Disable Custom Free Shipping Method from Front-end only in Magento 2?

Many times, you do not want to provide a free shipping method to your customers. But the orders placed from the admin grid should have a free shipping method. At that time, Magento store merchants come across the requirement to disable or remove the free shipping method from the store frontend only. Also, check out Shipping and Payment Method per Customer Group Extension which allows the store owner to manage shipping and payment method for the specific customer groups.

So, let’s find out How to Remove/Disable Custom Free Shipping Method from Front-end only in Magento 2?

Steps to Remove/Disable Custom Free Shipping Method from Front-end only in Magento 2:

Step 1: Go to the below path,

app\code\Vendor\Extension\etc\di.xml

And add this code,

Step 2: Now, go to the below path,

app\code\Vendor\Extension\Plugin\DisableEnableCustomShipping.php

And finally, add the code as mentioned below:

Conclusion:

Hence, with the help of the above code, you can easily Remove/Disable Custom Free Shipping Method from Front-end only in Magento 2. Also, check out Shipping and Payment Method per Customer Group Extension which allows the store owner to manage shipping and payment method for the specific customer groups. If you have any difficulty, mention it in the comment section. Do share the article further. See you soon till then stay in touch!

Happy Coding!

Click to rate this post!
[Total: 3 Average: 5]