Navigate to Shop Settings and clicking on Shipping
Click Add a Shipping Zone or Edit an existing one
Click the Shipping Methods tab and then click Add a Shipping Method or Edit an existing one
Set "Allow Product Based Shipping" to Yes
This will give you three options to restrict shipping method by:
This shipping method is the only one available on checkout: This means that this is the only shipping method that will appear in checkout. All other shipping methods will be hidden and the website user will only be able to use this option.
This method and other methods will be available on checkout: This means that other methods will appear in checkout with this method. The website user will have the option to choose this method or others at checkout.
Remove selected shipping method from checkout: This option means you are able to remove shipping method's from checkout. If this shipping method is applied to a product. A website user that checkouts with this product will not see the shipping methods you have removed.
Once you have setup a product based shipping method, you can update the product shipping option by:
Clicking on Shop Inventory, then Products.
Search for the product that you want to apply product based shipping to, and click "Edit".
Click on the Shipping tab, and select the Product based shipping method that suits this product.